Date range for a report

T

Tracey

Hi

I am trying to run a query and can't seem to nail down the right code.
We use the access database to track files, incoming/outgoing correspondence
dates etc.
I am trying to run a query that show me files with dates in a follow up
field of -60 days to +7 days, so essentially any follow ups missed in the
last 2 months and up coming in the next week.
This report is run on a weekly basis.

Appreciate any help

Thanks
 
J

Jerry Whittle

Assuming that the follow up field is actually a date/time data type, try this
in the criteria:

Between Date() - 60 and Date() + 7
 
J

John W. Vinson

Hi

I am trying to run a query and can't seem to nail down the right code.
We use the access database to track files, incoming/outgoing correspondence
dates etc.
I am trying to run a query that show me files with dates in a follow up
field of -60 days to +7 days, so essentially any follow ups missed in the
last 2 months and up coming in the next week.
This report is run on a weekly basis.

Appreciate any help

Thanks
= DateAdd("d", -60, Date()) AND < DateAdd("d", 8, Date())

will work (even if the datefield contains a time portion, hence the 8)
 

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