I made this query:
SELECT * FROM appointment WHERE day BETWEEN 1 AND 25 ORDER BY hour
It's return me all appointments of all days, is not bad but I need only 1 result per day.
So, I don't need "count(*) day 1, day 2, day 3..." because I need all information from this appointment.
If day 1 have 5 results, I need only one (and any) result of this day.
If day 2 have 1 result, ok, give me this one.
If day 3 have nothing, ok too
...
If day 25 have 9 results, I need only one (any) result.