MySQL Forums
Forum List  »  PHP

Re: Update column when datetime = NOW()
Posted by: Peter Brawley
Date: February 20, 2020 04:49PM

You said you need something to fire an update of the table. You do not. Given a View that defines a timestamp_value < Now() column, no such update is ever required.

If you have a number of such timestamps, and there is a requirement to notify certain users when certain timestamps reach a criterion date & time, you could create a notification table with a row for each such timestamp value, define Insert and Update Triggers to populate notification rows with notification times and email addresses of who's to be notified, have the app always track the next notification date in that table and watch the clock every minute or so, and fire off required notices when such times are reached.

Options: ReplyQuote


Subject
Written By
Posted
Re: Update column when datetime = NOW()
February 20, 2020 04:49PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.