|
-
Jul 25th, 2005, 02:17 PM
#1
Thread Starter
Frenzied Member
[RESOLVED] reset auto_number field in SQL Server
I have my reasons, so don't ask me why. I have an auto_number field in a database and that number is currently up to ~80,000 after some testing I've done. I'd like to reset that number to 0.
Anyone know how? SQL Server 2K SP3.
-
Jul 25th, 2005, 02:33 PM
#2
Fanatic Member
Re: reset auto_number field in SQL Server
In mysql you would use the expression in an update or alter statement
In sql server, you do this:
Code:
DBCC CHECKIDENT('table_name', RESEED, 0)
http://msdn.microsoft.com/library/de..._dbcc_5lv8.asp
-
Jul 25th, 2005, 03:04 PM
#3
Thread Starter
Frenzied Member
Re: reset auto_number field in SQL Server
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|