You can specify the next auto_increment id by using


Where # is your desired number. Will only work for the next INSERT/ALTER. 
Have a look down the bottom of 7.33 in the MySQL language reference.



Gavin Nouwens wrote:

> Hi peoples,
> Just wondering if it's possible with mysql to start an auto-increment
> field at a specified number instead of 0001?
> I could always just code it in php to add another number onto it to get it
> to the right start point, but leaves areas for human error to creep in!
> Any help would be appreciated!
> -gav.

PHP Database Mailing List (
To unsubscribe, visit:

Reply via email to