auto increment - how to reset it?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • jx2
    New Member
    • Feb 2007
    • 228

    #1

    auto increment - how to reset it?

    hi every1
    i had deleted last 3 thousands records but auto increment still see it and dont increment in order
    eg. the max value of 'id' is 12000 but when i insert next record id=15000 (should be 12001)

    how to make it count from 12001?
    thanks a lot

    jx2
  • pbmods
    Recognized Expert Expert
    • Apr 2007
    • 5821

    #2
    Use ALTER TABLE to reset the AUTO_INCREMENT value.

    P.S. Please don't bump your posts. Thanks!

    Comment

    • Motoma
      Recognized Expert Specialist
      • Jan 2007
      • 3236

      #3
      This is typically something you want to avoid. Most of the time there will be no reason to do this other than for your own whim.

      Comment

      • jx2
        New Member
        • Feb 2007
        • 228

        #4
        thanks a lot
        sorry about bumping...

        regards jx2

        Comment

        Working...