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

Error reported by the penultimate statement in a transaction is left over to COMMIT or ROLLBACK statements.

    XMLWordPrintable

Details

    Description

      The error reported by the penultimate statement in a transaction is left over to COMMIT or ROLLBACK statements, and BEGIN statement of another transaction in the same session.

      1. Test Case:

      /* init */ CREATE TABLE t0(c0 BOOLEAN PRIMARY KEY NOT NULL);
       
      /* tx1 */ BEGIN;
      /* tx1 */ INSERT INTO t0 VALUES (2136509845);
      -- ERROR 1264 (22003): Out of range value for column 'c0' at row 1
      /* tx1 */ COMMIT;
      /* tx1 */ SHOW WARNINGS;
      +-------+------+---------------------------------------------+
      | Level | Code | Message                                     |
      +-------+------+---------------------------------------------+
      | Error | 1264 | Out of range value for column 'c0' at row 1 |
      +-------+------+---------------------------------------------+
       
      In the same session
      /* tx1 */ BEGIN;
      /* tx1 */ SHOW WARNINGS;
      +-------+------+---------------------------------------------+
      | Level | Code | Message                                     |
      +-------+------+---------------------------------------------+
      | Error | 1264 | Out of range value for column 'c0' at row 1 |
      +-------+------+---------------------------------------------+
      

      We expect that COMMIT statement and BEGIN statement in the test case will not report a warning.

      Attachments

        Activity

          People

            sanja Oleksandr Byelkin
            John Jove John Jove
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:

              Git Integration

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