Using dates in reports. Is there a sample database?

C

C Tate

I am trying to get my head around using dates in reports (and queries). For
example pulling off all the, say, IT problems logged in the period Apr-June
07 in an issues IT issues database. Or any sort of database really.

I am not really sure how to use dates in reports and queries in this way and
none of the sample databases I've looked at really do this (Northwind or
some of the sample databases on the officeupdate site). I feel it would be
useful to see how it is done and would be grateful if anybody could point me
in the direction of a useful template/sample database.
 
S

Steve

You have a date field in the table where you log the IT problems. Create a
query based on this table and include the date field. For the period
Apr-June 07, put the following expression in the criteria:
Between #4/1/07# And #6/30/07#

The # signs keep Access from mistakenly thinking the slashes mean division.

For a generalized criteria, you can use:
Between [Enter Period Start Date] And [Enter Period End Date]

Here you will get two dialogs asking for the start and end dates.

PC Datasheet
Providing Customers A Resource For Help With Access, Excel And Word
Applications
(e-mail address removed)
 
G

Guest

Taking Steve's good reply a little further, you can create a form with a
couple text boxes to allow the user to enter the dates. This allows you to
check for integrity, provide defaults, use a calendar,...

Your query criteria would then look something like:
Between Forms!frmDates!txtStart and Forms!frmDates!txtEnd

--
Duane Hookom
Microsoft Access MVP


Steve said:
You have a date field in the table where you log the IT problems. Create a
query based on this table and include the date field. For the period
Apr-June 07, put the following expression in the criteria:
Between #4/1/07# And #6/30/07#

The # signs keep Access from mistakenly thinking the slashes mean division.

For a generalized criteria, you can use:
Between [Enter Period Start Date] And [Enter Period End Date]

Here you will get two dialogs asking for the start and end dates.

PC Datasheet
Providing Customers A Resource For Help With Access, Excel And Word
Applications
(e-mail address removed)


C Tate said:
I am trying to get my head around using dates in reports (and queries). For
example pulling off all the, say, IT problems logged in the period Apr-June
07 in an issues IT issues database. Or any sort of database really.

I am not really sure how to use dates in reports and queries in this way
and none of the sample databases I've looked at really do this (Northwind
or some of the sample databases on the officeupdate site). I feel it would
be useful to see how it is done and would be grateful if anybody could
point me in the direction of a useful template/sample database.
 

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