Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SQL Sate - elimate post-dates

Status
Not open for further replies.

tyleri

Programmer
Jan 2, 2001
173
US
I want the asp code to only display dates including the current date and any future dates. how can I eliminate any expired dates?

here is what i have to work with now:

Set rstSimple = cnnSimple.Execute("SELECT * FROM shows")
 
Dim dateToday
dateToday = Date
Set rstSimple = cnnSimple.Execute("SELECT * FROM shows WHERE date >=" & dateToday )

Depending on the database you may need to convert dateToday to a string and add quote marks or # around the string.

. . . WHERE date >=#" & CStr(dateToday) & "#" . . .
or
. . . WHERE date >='" & CStr(dateToday) & "'" . . .

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top