Sorting through date

tsukeepr

Registered User.
Local time
Today, 17:37
Joined
Jun 6, 2002
Messages
11
I need to build a query that allows me to show all form entries in the past 7 days. I have a date entered feild already. I also have an ID # that is a primary key, and I would like to build a query that allows me to pull from a particular ID number foward. Any Ideas?
 
I re-read your question twice because somehow it sounds like a trick question.

If the date entered is available as a field, you don't need the ID for much if anything. You could write a query with a column that specifies

DateDiff( "d", [EventDate], Now() )

and a criterion of <= 7

The only thing you would need your ID number for is perhaps to sort the remainder of the records. But since it is your primary key, the records will already appear in ascending order of the ID number anyway.
 
Thank you so much, it worked great!!
 

Users who are viewing this thread

Back
Top Bottom