Select Max question

Kurt Klamp K.Klamp at t-online.de
Sun Jan 25 09:38:47 CST 2004


Keith DeLong wrote at 25.01.2004 7:32 Uhr

>SELECT Max(Date_Entered)
>FROM Matters
>Where Person_ID = 4
>
>I got the same result as above. After some experimentation it seems
>Valentina is ignoring the WHERE clause all together when Max is used. This
>seems also true for Distinct.  Is this the normal way for SQL to work or a
>Valentina oddity?
>
>Is there is a query solution that I am missing at this late hour of a long
>week?
Hi Keith,

i had the same problem.  the following should work:

SELECT Person_ID, Max(Date_Entered)
FROM Matters
Group by Person_ID

i think there must be a use of group by when using a aggregate function.

Best,
Kurt


More information about the Valentina mailing list