Query DATE

  • Thread starter Thread starter tye
  • Start date Start date
T

tye

Hi,

I need to get the sales for a whole week from my database,
but the date is in this format 20040806110632, so its got
the date backwards also after the date its got the time of
the sale.

What i want the query to do is,
Enter the date i want e'g 20040802 (Start date)to 20040806
(End Date) so it list all the sales per agent.

At the moment we can pull up Sales for one day only.
The query that is set it this.

Field:Date: Left([TransactionID],8)

Total:Group by

Criteria: Like([Enter Date - YYYYMMDD] & "*")

Thanks

tye
 
Tye

In your query, use that new field for date (by the way, do NOT name it
"Date" - this is a reserved word in Access), maybe something like:

MyDate: Left([TransactionID],8)

and in the criterion beneath it, use a pair of parameters and the Between
.... And comparison, as in:

Between [Enter your 'from' date as yyyymmdd] And [Enter your 'to' date
as yyyymmdd]
 
Back
Top