Setting Up A MySQL Event

  • Answered
On a shared server, how do I run an event or a procedure that truncates the same table at midnight every Sunday? I realize I might be able to get this to work using a CRON job, but I don't necessarily want to go that route.
Hello ehauser0163, Thank you for your question about MySQL events. You are correct in assuming that there is a limitation on shared access to the Event Scheduler. A cron job would be your best option in a shared environment. However, if you have a VPS server, you get full access to MySQL services. However, even in a VPS environment crontab is more often recommended because it is more widely used. Best, Christopher M.