sql - Validating date has expired with current system date -
i trying compare database stored date value current system date. date format (yyyy-mm-dd). , sql date written compare follows.
select id table1 tabel1.date > current_date
and want result if date has been expired or not.
please find me correct sql.
thanks in advance
well, when tabel1.date > current_date
date stored in database in future.
try
select id table1 tabel1.date < curdate();
Comments
Post a Comment