I'm crashing my head over a design decision, and I'm trying to get some more inspiration/hints/tips/.. from other programmers.
What is the goal:
I want to run one cron task (php script) every minute.
In this script I should check a database full of schedules (same syntax as cron jobs) to see if an action should run right now. (An action can be sending out an email, sending out text-message, ..)
I don't think it's possible with sql only, so the best is to retrieve all schedules, and check in PHP which one of them should be executed at the given moment.
I'll also store the "startFrom" date, to say when this schedule should be triggered first.
Any suggestions on this one?