qry between dates

pollypocket

Registered User.
Local time
Today, 22:41
Joined
Sep 4, 2003
Messages
16
any advise on qry's between dates,

i need to generate a report that pulls out info between two dates eg start 01/09/03 end 07/09/03 any suggestions?
 
Many, but depending upon your final wana have....

You might want this week (mon thru sun) or last week

For this week: between date()-weekday(date(),vbmonday)+1 and date()-weekday(date(),vbmonday)+7

Many other option tho depending... bla bla...

Regards

The Mailman
 
I usually take a calendar approach and reference the textboxes in the query:

i.e.


Between [Forms]![frmMyForm]![txtStart] And [Forms]![frmMyForm]![txtEnd]


Check out the example...
 

Attachments

date qrys

will always be from the previous week ie rpt next week 07/09/03 - 14/09/03.... probably a stupid question but this is all new to me where do i type this criteria?!
 
If you were reporting today you would want the data to show results Between 25 aug and 31 aug ?!

between date()-weekday(date(),vbmonday)-6 and date()-weekday(date(),vbmonday)

Put that in the criteria line of the Query builder (QBE) under the date field you wish to limit.

Regards
 
or alternatively, you can put this in the criteria line of the date field in the query.

Between [StartDate] and [EndDate]

Then you'll be prompted for each date in a parameter box (just in case some clever dick wants a months worth of data, instead of a week:rolleyes: )

The choice is yours

Col
 

Users who are viewing this thread

Back
Top Bottom