Originally Posted by
Minty
Just post up the real SQL. We will be guessing without seeing it.
Code:
SELECT myTable.myItem, mytable.myFlag, myTable.Comment, Max(myTable.myDate) AS MaxOfMyDate
FROM myTable
GROUP BY myTable.myItem, myTable.myFlag, myTable.Comment, myTable.MyDate
HAVING myTable.myFlag LIKE"L";
I have stripped the SQL to the bare minimum to illustrate the point and not introduce other fields and criteria to confuse the issue.
This exact SQL will return just two lines for each item which as multiple records containing flags or L (uppercase) or l (lower case)