Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-16891

EVENTs created with SQL_MODE=ORACLE fail to execute

    Details

      Description

      How to reproduce:

      Create the same event doing a simple "SELECT 1"
      in default and 'ORACLE' sql_modes:

      SET GLOBAL event_scheduler=1;
       
      SET sql_mode='';
      CREATE EVENT e1 ON SCHEDULE EVERY 1 MINUTE  DO SELECT 1;
       
      SET sql_mode='ORACLE';
      CREATE EVENT e2 ON SCHEDULE EVERY 1 MINUTE  DO SELECT 1;
      

      Creating the events succeeds just fine without problems.

      But when it is time to execute the events the one that was created while "ORACLE" mode was in effect fails with a syntax error:

      2018-08-03 11:38:11 14 [ERROR] Event Scheduler: error during compilation of test.e2
      2018-08-03 11:38:11 14 [ERROR] Event Scheduler: [root@localhost][test.e2] You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'select 1' at line 1
      2018-08-03 11:38:11 14 [Note] Event Scheduler: [root@localhost].[test.e2] event execution failed.
      

        Attachments

          Activity

            People

            • Assignee:
              bar Alexander Barkov
              Reporter:
              hholzgra Hartmut Holzgraefe
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: