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

LP:314570 - update is not changing internal auto increment value

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Trivial
    • Resolution: Not a Bug
    • None
    • None
    • None

    Description

      create table t1 (a int not null auto_increment primary key, val int);
      insert into t1 (val) values (1);
      update t1 set a=2 where a=1;
      insert into t1 (val) values (1);

      leads to:

      drizzletest: At line 307: query 'insert into t1 (val) values (1)' failed: 1062: Duplicate entry '2' for key 'PRIMARY'

      For InnDB this fails, for MyISAM, it passes as MyISAM updates the auto increment value.

      Attachments

        Activity

          People

            Unassigned Unassigned
            aartipai Aarti Pai (Inactive)
            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.