Code: Select all
SELECT test.id, test.date, test.house
FROM test INNER JOIN test AS t2 ON datevalue(test.date) = datevalue(t2.date) and test.house = t2.house
GROUP BY test.id, test.date, test.house
having test.date = max(t2.date)
order by test.date
[/quote]
PS having will do the job, but it's the most unefficient way to use SQL