5
I intend to create an event so that every hour will see if the expiration date of the announcement is higher than the current date, in this case it will have to change a theme of this announcement in the database, that is, it would be something like this that I tried, but I doubt how to get the instantaneous date:
CREATE EVENT e
ON SCHEDULE EVERY 1 HOUR
DO UPDATE anuncios SET estado=3 WHERE dataexpiracao > -data actual-
Okay I really appreciate
– Pedro Piloto