Wednesday, 11 November 2009

SQL Server Set Identity Seed

DBCC CHECKIDENT (table_name, RESEED, new_reseed_value)

E.g.
DBCC CHECKIDENT (Customers, RESEED, 2000)

From Microsoft: Checks the current identity value for the specified table and, if it is needed, changes the identity value. You can also use DBCC CHECKIDENT to manually set a new current identity value for the identity column.

Full article: http://technet.microsoft.com/en-us/library/ms176057.aspx

No comments: