iif statement in a query

tdenmark

New member
Local time
Today, 13:41
Joined
Aug 24, 2005
Messages
1
I have this query that I want to return only records where the date(mm/dd/yyyy) is less than 30 days old. Anybody got a suggestion?
 
WHERE DateField > (Date() - 30)
 
in Criteria section where the date field is put
Now()-[Date]<30

[Date] (Date is name of column)
 
nshah1013,

In addition, if your field is named [date], rename it. MyDate, YourDate, whatever...but not [Date]. 'Date' is a reserved word, the name of a function, and it will ultimately come back to bite you.

Bob
 

Users who are viewing this thread

Back
Top Bottom