This is from the docs ..... "The auto-increment value of a deleted record will 
only not be reused until the server is restarted, then it will be reused. In 
other words, if you insert 10 rows into an InnoDB table and then delete them 
the AUTO_INCREMENT value will stay at 11 until the server is shutdown at which 
point it will revert to 1!!!""

Now if i have records 1 to 10 and i delete some records in between , say, 5, 7, 
8. Now when i restart my server, will these values of 5, 7 and 8 be reused??  

Does it mean that the autoincrement values of deleted records will be reused 
only if ALL records are deleted and then server restarted?? 

From docs .... "  Note that you may see gaps in the sequence of values assigned 
to the AUTO_INCREMENT column if you roll back transactions that have gotten 
numbers from the counter.  "
Does InnoDB reuse these gap  values at any time ??? 

Thanks 
Priya

Reply via email to