How To Reseed An Identity In SQL Server Using T-SQL



TODO:

Have you ever wanted to reseed an Identity column in your database?

 

SOLUTION:

DBCC CHECKIDENT (yourtablename, reseed, 1)

 

NOTES:

The above command will reset the identity to start at 1.  You can set that to any value you would like.



Add comment

  Country flag

biuquote
  • Comment
  • Preview
Loading