I would like to ask a solution for mysql database. since i made database(order) about 3 column named as order_date(datatype - date),expired_date(datatype - date) and status(varchar(10)).
as status value are only New and Expired.[as only 'New' input from user]
The main process I want is
- as expired date(calculated from order_date) should know that currentday is doing well
- if currentday is greater than expired date. database should be triggered and update status column 'New' into 'Expired'
as far I know to accomplish this I should use an SQL trigger. How can I implement a trigger for the above use case.