Sorting through date (1 Viewer)

tsukeepr

Registered User.
Local time
Today, 16:05
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?
 

The_Doc_Man

Immoderate Moderator
Staff member
Local time
Today, 10:05
Joined
Feb 28, 2001
Messages
27,195
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.
 

tsukeepr

Registered User.
Local time
Today, 16:05
Joined
Jun 6, 2002
Messages
11
Thank you so much, it worked great!!
 

Users who are viewing this thread

Top Bottom