Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to reset count for identity field?
Message
General information
Forum:
ASP.NET
Category:
Databases
Miscellaneous
Thread ID:
00819923
Message ID:
00820654
Views:
18
When you say "move your data manually ... by just doing regular inserts," are you saying there's an efficient way to do this? The task of building individual INSERT statements for, say, 10,000 records would be horrendous—but maybe I'm missing something.

One could do an export to CSV and then import, yes, but wouldn't that method overwrite—or worse, shift one field to the right—the identity field?



>Not nessarily. It depends on how you migrate your data. If you use the Import/Export Wizard it will preserve the identitiy values by setting identity insert to on. If you move your data manually you can reset the identity values by just doing regular inserts, but be careful if you have any relationships defined that you update those keys too.
>
>Eric

Read about the greatest fraud in the history of mankind.
See TaxableIncome.net.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform