I created a table with an auto_increment field and made some test posts. Now I deleted those posts and I want to reset it so the first post is 1 again. How is this done?
| SitePoint Sponsor |
I created a table with an auto_increment field and made some test posts. Now I deleted those posts and I want to reset it so the first post is 1 again. How is this done?





If everything is removed from the table, the auto_increment field resets automatically I belive..
- website





and by reading the manual I found this
ALTER TABLE tbl_name AUTO_INCREMENT = 100
will start your records at 100
ALTER TABLE tbl_name AUTO_INCREMENT = 1000
will start your records at 1000
- website
Bookmarks