Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How can I make the automatic key(SQL server) start over?
Message
 
 
To
22/03/2000 10:47:55
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00348885
Message ID:
00348937
Views:
28
>Diane,
>
>> I am working with VFP 6.0 and using automatic key field increment from SQL server for all the views I have. During the time of working with them, the key fields have been increasing and they are big numbers now. Is there any way that I can make them start over at 1 or less than the numbers I have righ now?
>
>Why do you want smaller numbers? Are you using the keys for some purpose other than as keys, like perhaps for invoice numbers or customer numbers? If not, there should be no reason to reset the keys. If so, you probably should consider letting relational keys be just that, with no other purpose.
>
>Are your data tables so large that you are running out of numbers?

I agree with David about not doing this. Changing the keys could cause serious RI issues throughout your database as well as primary key conflicts.

But if you do want to, go into Enterprise Manager, select the database and table you want to change. Go into Design Table and change the Identity Seed value for the field. The increment will start from the new value.
Larry Miller
MCSD
LWMiller3@verizon.net

Accumulate learning by study, understand what you learn by questioning. -- Mingjiao
Previous
Reply
Map
View

Click here to load this message in the networking platform