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

Inconsistency upon inserting history with visible system versioning columns

    XMLWordPrintable

    Details

      Description

      Filing as 10.11v1- critical as previously discussed, to make it show up on the list for consideration. Please feel free to downgrade or close as "won't fix".

      For a table with visible versioning columns, setting system_versioning_insert_history variable changes the behavior of inserting default values (restricts it).

      create or replace table t (a int auto_increment primary key, s timestamp(6) as row start, e timestamp(6) as row end, period for system_time (s,e)) with system versioning;
      set system_versioning_insert_history=off;
      insert into t () values (),();
      insert into t (a) values (3),(4);
      set system_versioning_insert_history=on;
      insert into t (a) values (5),(6);
      insert into t () values (),();
      

      Both INSERTs with system_versioning_insert_history=off work, with a values inserted according to the auto-increment or explicit values, s to the current time, and e to the max timestamp.
      The third INSERT, first with system_versioning_insert_history=on also works, the same way.
      But the last INSERT fails:

      bb-10.11-MDEV-16546 2b1d32429

      query 'insert into t () values (),()' failed: ER_WRONG_VALUE (1525): Incorrect s value: '0000-00-00 00:00:00.000000'
      

      There seems to be no good reason for this.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              serg Sergei Golubchik
              Reporter:
              elenst Elena Stepanova
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.