At 3:15 PM -0400 9/17/01, Jay Fesco wrote:
> > Can someone tell me how to reset a column's auto_increment starting point
>> back to 0 in mysql ?
>According to Paul DuBois on page 169 of MySQL by New Riders (which you
>ALTER TABLE t
> DROP i,
> ADD i INT UNSIGNED AUTO_INCREMENT NOT NULL PRIMARY KEY
Actually, this will drop the column and renumber the rows sequentially.
To just reset the sequence to 0 (well, to 1, since sequences start at 1),
ALTER TABLE t AUTO_INCREMENT = 1
Paul DuBois, paul@stripped