php - Resetting the ID in phpmyadmin -
i working on mysql database had id's auto-incremented 00001. reason, changed reset 2000, client wants reset again 00001. tried following :
alter table table_name auto_increment=00001
in sql part of phpmyadmin, have tried these steps :
1) select table 2) goto operations 3) goto table options 4) change auto increment value
in both ways, not able reset value.
can done via phpmyadmin:
- on id column, remove auto-increment setting
- delete primary key in structure > indexes
- create new column future_id primary key, auto_increment
- browse table , verify new increments correspond you're expecting
- drop old id column
- rename future_id column id
- move new id column via structure > move columns
Comments
Post a Comment