MySQL schedular every day in a time periode every hour This schedular i made doesn't work how i would like it to work.

The idea is that it will run every day in a time periode from 06:15:00 till 23:59:59 and in that only periode run every hour

That means it will run on 06:15 - 07:15 - 08:15 etc.. till 23:15 and start over again the next day

Server version: innodb_version:5.7.25

DELIMITER |

/*  6  7  8  9  10  11  12  13  14  15  16  17  18  19  20  21  22  23  */ 
ALTER 
    EVENT `Database`.`Import_data01_view` 
    ON SCHEDULE 
        EVERY 1 HOUR 
        STARTS '2019-04-15 06:15:00'  ON COMPLETION PRESERVE ENABLE
    DO BEGIN

/* do things */


END |


DELIMITER ;


With the info i found my own solution for it:

DELIMITER |

/*  6  7  8  9  10  11  12  13  14  15  16  17  18  19  20  21  22  23  */ 
ALTER 
    EVENT `Database`.`Import_data01_view` 
    ON SCHEDULE 
        EVERY 1 HOUR
        STARTS str_to_date( date_format(now(), '%Y%m%d 0615'), '%Y%m%d %H%i' )
        ON COMPLETION PRESERVE ENABLE
    DO BEGIN


 IF time(CURRENT_TIMESTAMP) between time('06:14:59') and time('23:59:59')
      THEN

/* doe something */



end if;







END |


DELIMITER ;
-- main action to perform at 6:15 - 7:15 - ... 23:15
CREATE PROCEDURE main_action()
BEGIN
    -- ...
END;

-- event procedure
CREATE PROCEDURE evt_action()
BEGIN
IF HOUR(CURRENT_TIMESTAMP) &gt; 5 THEN 
    CALL main_action();
END IF;
END;

-- event
CREATE EVENT evt_name
ON SCHEDULE EVERY 1 HOUR STARTS '2019-04-15 06:15:00'
DO CALL evt_action();

-- start scheduler
SET GLOBAL event_scheduler = ON;