#5235Requested

Prevent Auto_Inc PK columns collisions after inserting PK manually ie because of migrations

Requested by @Pepn
Energy Committed7,001TeVfrom 1 booster

After you manually insert anything in a auto inc pk column you boobytrapped your table waiting for auto pk insertions to collide nastily. Lots of users have had to roll their own collision prevention or even create their own PK tables. As if you ever have pk autoinc columns and manual data migration you will run into this problem.

Auto Inc PKs should skip the value and attempt the next one or start at the max value or smth. GL!

  1. website-features added the feature-request label Jun 4, 2026

Boost this Request

Reopen this request?

The request will return to its prior live status.

Mark as Duplicate

Pick the request that Prevent Auto_Inc PK columns collisions after inserting PK manually ie because of migrations is a duplicate of. Energy rolls up into that request and GitHub closes the linked issue as a duplicate with a timeline reference to the canonical.

Unmark Duplicate

Restore as an independent request. The linked GitHub issue will be reopened and its duplicate-of relationship cleared. The original timeline entries stay as history; the note below is posted as a follow-up comment.