Oldest date (1 Viewer)

sandhurstUK

Must change my user name
Local time
Today, 17:34
Joined
Feb 15, 2002
Messages
42
Hi,

The following code selects a list of surveyors and a list of dates.
What would be the next line of code to select just the oldest date per surveyor?


SELECT [Current NBIs Grouped qry].Surveyor, [Current NBIs Grouped
qry].[Allocation Date]
FROM [Current NBIs Grouped qry]
GROUP BY [Current NBIs Grouped qry].Surveyor, [Current NBIs Grouped
qry].[Allocation Date];

Thanks
Ian
 
R

Rich

Guest
Look up Max([MyDate]), there have been numerous examples posted here
 

sandhurstUK

Must change my user name
Local time
Today, 17:34
Joined
Feb 15, 2002
Messages
42
Derrrrrr

Sorry folks, it was a bit early when I posted that.

SELECT [Current NBIs Grouped qry].Surveyor, Min([Current NBIs Grouped qry].[Allocation Date]) AS [MinOfAllocation Date]
FROM [Current NBIs Grouped qry]
GROUP BY [Current NBIs Grouped qry].Surveyor;

This worked fine.

:D
 

Users who are viewing this thread

Top Bottom