I am using MS Access DB and Dreamweaver to produce a front end web page. I have a column 'NextCallDate' in the database, and a text field on my web page 'MMColParam' in which a number of days can be entered. What I want to acheive is a list returned with all of the rows that have a 'NextCallDate' which is within the next 'MMColParam' number of days.
The statement I have at the moment is:
SELECT * FROM [Main - Personal Details] WHERE DateDiff('d', NextCallDate, now()) < 'MMColParam' & DateDiff('d', NextCallDate, now()) > -1
but this does not work as I get entries returned that have a NextCallDate which is in 2012!
Can anyone please help?