Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Reset an autoincrement value

Status
Not open for further replies.

Joell

Technical User
Oct 4, 2002
10
AU
Any ideas as to how i could reset an antoincrement value for paradox tables? I've tried the minimun value 'thing' through database desktop and it doesnt work.

Cheers,
jOeLL
 
I don't use auto-increment lots of reasons, but to answer your question, the only way I know is:
1. Copy your table (ORIG.DB) to say COPY.DB
2. Empty ORIG.DB (you did check that the copy worked!)
3. Restructure ORIG.DB and set the min value (e.g. 70)
4. Add COPY.DB to ORIG.DB

NB: ALL the previous auto-increment values will be replaced with values starting at the min value specified (in the above case 70) and incrementing by 1.

I'm not sure if this is what you want to achieve.

Padraig
 
I have done this by restructuring the table:
1. Delete the autoincrement field
2. Save the structure
3. Insert the autoincrement field again
4. Save.
This will start the numbering at 1.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top