-1
I just want to do a comparison of dates in Mysql but I can’t. Help me, it’s to see if the date is greater than or equal to a date, and less than another date.
SELECT
(CASE
WHEN '2019/12/05 00:00:00' >= age_start THEN 'existe'
WHEN '2019/12/05 00:00:00'<= age_end
ELSE 'okay'
END)
FROM agenda
After researching I arrived at this code but it is not certain, why?
It would not be simpler something like:
SELECT * FROM agenda WSHERE age_start <= '2019/12/05 00:00:00' AND age_end >= '2019/12/05 00:00:00';
?– anonimo