Start/End Dates, & what's in between 'em

  • Thread starter Thread starter Uverga
  • Start date Start date
U

Uverga

Guest
My table has a StartDate and EndDate along with meeting information.

Start End Meeting
10/8/01 10/11/01 Brakes Workshop
10/9/01 10/9/01 Transmission Workshop

I would like to report the meeting information for one week at a time.

10/8/01 Brakes Workshop
10/9/01 Brakes Workshop
10/9/01 Transmission Workshop
10/10/01 Brakes Workshop
10/11/01 Brakes Workshop

Problem: How can Access 2000 list information for dates that are IN BETWEEN the StartDate and EndDate? (example: 10/9/01 & 10/10/01 Brakes Workshop)

Thank you for your help.
 
You'll have to create a custom function to generate the dates since they aren't stored anywhwere in your db.
HTH
 
What would a custom function for this problem look like?
 
If you run a query, looking for all info.

In my example i am looking for all flight details between txt_date and txt_dateto - which are 2 fields on my form - so i enter the dates and it finds all the info between these dates (for flights belonging to the resort )

SELECT [flights].[flightid], [flights].[departairport], [flights].[arriveairport], [flights].[traveldate], [flights].[duration], [flights].[flightname], [flights].[price], [flights].[flightsresortid]
FROM flights
WHERE ((([flights].[traveldate]) Between [Forms]![flights]![txt_date] And [Forms]![flights]![txt_dateto]) And (([flights].[flightsresortid])=[flightsresortid]))
ORDER BY [flights].[traveldate];

So in your query, drag all the required info, then in the criteria for the date, type
BETWEEN [Forms]![formname]![datefield1] AND [Forms]![formname]![datefield2]

that should do it !!

HTH
 

Users who are viewing this thread

Back
Top Bottom