Well, I'll try one more time.
I'm using Dreamweaver MX to generate ASP. I'm connecting to an ACCESS DB. This is my SQL string:
--------------------------------------------
RecsetTimesheets.Source = "SELECT * FROM Timesheets WHERE CustomerListID = '" + Replace(RecsetTimesheets__MMColParam, "'", "''") + "' AND ORDER BY DateTaught ASC"
-------------------------------------------
*** NOTE ***
This takes the parameter passed from the URL:
" + Replace(RecsetTimesheets__MMColParam, "'", "''") + "
************
I want to filter the date by DateTaught
I have a variable from another table that tells me how many days to display at a time:
(RecsetCustomer.Fields.Item("LessonDisplay").Value )
This variable is a simple number. I want to take the current date, then subtract my variable from it, and then show all DateTaught rows that are greater than it. Something like this forula:
Show all records where DateTaught >= (TodaysDate - dayVariable)
I could write this in ASP or Javascript, but how do I do it in SQL?