Can someone, with more knowledge of HSQL then I, please give me a clue with the following:
I’m trying to produce a query that displays overdue treatment (mainly vaccinations) for the named dogs, from the table below:
The following query attempts to find the animals that are overdue, but fetches record that are not over due.
With the ’ AND CURRENT_DATE > “dt”.“due_date” ’ line active (not commented out), while the records with a ‘due_date’ of later than today are not retrieved (good), an older record with the next latest date are retrieved, like so:
What I want are the latest records where the ‘due_date’ is less than today. I don’t seem to be able to get my pea-like round the logic.