Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

query refined

Status
Not open for further replies.

jewel

Technical User
May 23, 2001
158
NZ
hey all
I have a command button on form - opens query - four relevant fields in query - driver // fleet no (parameter asking for fleet no) //Outdate // Indate.
eg Driver Smith //fleet no 412 // outdate 21/09/01 //indate 24/09/01

At the moment it comes up in datasheet view and because it uses an archive table eg previous month it can have quite a few records on it. At the moment we just have it in descending order which is okay but would like to refine it.

If I get a ticket on the 23/09/01 how can I build a refined query to find who had the vehicle on this date?

if not clear please get back to me

cheers
 
Add the following to the Criteria of your query:

For field outdate add:

<=[Ticket Date]


For field indate add:

>=[Ticket Date]


This will prompt you to enter ticket date and then only return those records where the ticket date falls between the out and in date.
 
thanks Jitter - this time I was looking for the hard solution - works fine on the ones I have tested.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top