last date entered

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Thanks for the help. I'm using Office 2003. I have a table with a field of
dates. In my query I need to ask for the most recent date from the list. How
can I do that?
 
Using a group by Query with Max on the date field

SELECT Max(DateField) AS MaxDate
FROM MyTable
===========================
Or using code with DMax

Dmax("DateFieldName","TableName")
=============================
 
SheriTingle said:
Thanks for the help. I'm using Office 2003. I have a table with a field of
dates. In my query I need to ask for the most recent date from the list. How
can I do that?

You can retrieve the entire or any combination of fields in
the latest record by using:

SELECT TOP 1 field1, fieldx, . . .
FROM thetable
ORDER BY thedatefield DESC
 
Back
Top