Date Query

L

Les

Hello

I'm trying to build a query that shows me all records where a field is older
than 90 days from today or are null.
I've tried using <Now()-"90" Or Is Null but this doesn't give the desired
results.
What am I getting wrong?

Thanks
 
J

John Spencer

Assumption: Your field is a date field

Field: YourDateField
Criteria: Is Null Or <DateAdd("d",-90,Date())

Or try dropping the quotes in your expression so it reads

Field: YourDateField
Criteria: <Now()-90 Or Is Null

--
John Spencer
Access MVP 2002-2005, 2007
Center for Health Program Development and Management
University of Maryland Baltimore County
..
 
L

Les

Cheers John

Worked a treat.

Les.


John Spencer said:
Assumption: Your field is a date field

Field: YourDateField
Criteria: Is Null Or <DateAdd("d",-90,Date())

Or try dropping the quotes in your expression so it reads

Field: YourDateField
Criteria: <Now()-90 Or Is Null

--
John Spencer
Access MVP 2002-2005, 2007
Center for Health Program Development and Management
University of Maryland Baltimore County
..
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top