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

Upgrading to 10.2 breaks auto increment

    XMLWordPrintable

Details

    Description

      How to reproduce:
      1. Install old MySQL (I was using Percona).
      2. Create a table with auto_increment = something
      3. Insert some rows
      4. Upgrade to MariaDB 10.2
      5. Inserting new rows causes Duplicate entry 'xxx' for key 'PRIMARY'

      I think this issue is related to how MariaDB 10.2 handles auto_increment. Before, it would recalculate the next auto_increment every time the server was started. Now it is persistent, but after an upgrade, it uses the old auto_increment that was in the initial create table statement.

      A workaround is to remove the auto increment and add it again.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              bichinhoverde bichinhoverde
              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.