Need Help with Date Query

K

Katherine R

I want to filter records so I will get the most recent date for each ID
Number. I'd like to do this in a query. I want to do a report from the
query that shows the last time a license certificate was issued.

Thank you.
 
J

John Vinson

I want to filter records so I will get the most recent date for each ID
Number. I'd like to do this in a query. I want to do a report from the
query that shows the last time a license certificate was issued.

Thank you.

Use a criterion like this on the date field: (bear in mind I cannot
see your database and don't know any of your table or fieldnames):

=(SELECT Max([datefield]) FROM [yourtable] AS X WHERE X.[ID Number] =
[yourtable].[ID Number])


John W. Vinson[MVP]
 
J

John Spencer

SELECT *
FROM YourTable
WHERE CertificateDate =
(SELECT Max(CertificateDate)
FROM YourTable As Temp
WHERE Temp.ID = YourTable.ID)

If you post your table name and the names of the fields you want, someone
can probably give you a more specific solution.
 
J

Jeff Boyce

Disregard the "you can't do this" response. It is either SPAM or something
worse. Follow the link at your own peril!

The person posting the response has used several different aliases, and is
now representing him/herself as an MVP.

Regards

Jeff Boyce
Microsoft Office/Access MVP
 
Top