Failed to read auto-increment value from storage engine, Error Number: 1467

后端 未结 9 912
[愿得一人]
[愿得一人] 2020-12-16 02:54

When inserting data in mysql i get this error:

Error Number: 1467 Failed to read auto-increment value from storage engine

I don\'t now how to solve this i

9条回答
  •  半阙折子戏
    2020-12-16 03:35

    As spencer7593 says, the autoincrement value has reached the maximum value for the datatype

    I just came to the problem.

    use the command SHOW CREATE TABLE tablename;, I get

    table name {
    `id` int(11) NOT NULL AUTO_INCREMENT,
     ......
    }ENGINE=InnoDB AUTO_INCREMENT=100000000000 DEFAULT CHARSET=utf8 
    

    You will see the length of 100000000000 is 12, beyond the limit 11.

提交回复
热议问题