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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Auto numbers

Status
Not open for further replies.

peljo

Technical User
Mar 3, 2006
91
BG
The auto numbers of my tables begin with 1000 and i have reached 1500. Which is the best way to to preserve the old auto numbers and begin the numbering with 2000?
 
First, let me prefix anything else I say by saying that autonumbers SHOULD NOT have any meaning whatsoever. They are a way to ensure a unique identifier and maintain referential integrity. If you are using them to mean something, you are probably using them wrong (in my and many other programmers opinions). There are a few FAQs on this topic, but I can't seem to find them right now.

That being said, take a look at faq700-583, faq181-1023 and faq700-184 They all relate to autonumbers and reseeding the table or similar ideas.

=======================================
People think it must be fun to be a super genius, but they don't realize how hard it is to put up with all the idiots in the world. (Calvin from Calvin And Hobbs)

Robert L. Johnson III
CCNA, CCDA, MCSA, CNA, Net+, A+, CHDP
VB/Access Programmer
 
And the SQL way:
ALTER TABLE yourTable ALTER COLUMN yourAutoNum COUNTER(2000,1)

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top