Select Query - The Most Recent Date

brucey54

Registered User.
Local time
Today, 15:03
Joined
Jun 18, 2012
Messages
155
How would you write a Select Query to select the most recent dates?


Select OrderDates
From Orders
Where >=Date()

No good if recent date is older than todays date!!!!!!!!!!!!!!!
 
select max(orderdates) from orders

?? That what you are after ??

Or
Select * from orders where orderdates = (select max(orderdates) from orders)

?? That what you are after ??
 
This will be an aggregate (Totals) query where you group on the field identifying what you want the last date of and max on the date.

Brian
 

Users who are viewing this thread

Back
Top Bottom