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!

Reset Identity Field

Status
Not open for further replies.

Waynest

Programmer
Jun 22, 2000
321
GB
Hello

I have a system which is to go live in the next week or two.

A few of my tables have fields of type 'int' where they are set up as identity fields (Autonumber).

I would like the identity fields to start counting from 1 when the system goes in, how do I reset them?

Thanks
 
try something like this

dbcc checkident(tablename,reseed,1)

you will need to have deleted the data or truncated the tables first.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top