Duplicate entry '2147483647' for key 1

前端 未结 12 772
南笙
南笙 2020-12-18 21:41

Strange problem I can\'t seem to get my head around. I have a table in a MySQL database with the following structure...

    CREATE TABLE IF NOT EXISTS `tblb         


        
12条回答
  •  轮回少年
    2020-12-18 22:43

    Try changing the auto_increment column to bigint instead of int, then the max value would be '9223372036854775807' or even '18446744073709551615' if you make it unsigned (no values below 0).

    Change your Auto_Increment to the last id in the column so it is continued where it left off.

    Be sure you do not delete auto_increment, otherwise it will continue to produce the error.

提交回复
热议问题