Mysql事件查看及定時器相關操作 查看事件 SHOW EVENTS select * from mysql.event 查看是否開啟定時器 SHOW VARIABLES LIKE 'event_scheduler'; 開啟定時器 0:off 1:on SET GLOBAL event_scheduler = 1; . 刪除 drop EVENT *_event; 創建 CREATE EVENT IF NOT EXISTS *_event_test ON SCHEDULE every 1 Hour DO CALL update_*_proc(); 或者 CREATE EVENT IF NOT EXISTS update_*_event ON SCHEDULE every 1 DAY STARTS TIMESTAMP(CURRENT_DATE,'00:05:00') ON COMPLETION PRESERVE ENABLE DO CALL update_*_proc(); date_add(date(curdate() + 1),interval 8 hour)