Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Primary Keys when deleted can't be reused untill pack
Message
 
To
06/05/2000 20:06:34
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00367026
Message ID:
00367069
Views:
18
>How are developers handling the problem where a primary key and data record is added to a table. The user decides to start the record over so they delete the record. When they start to add the record again with the same key, they will get a duplicate key message because the key, although deleted, is still in the index, until I pack the file. One idea would be to change the key when I delete the record. Is there a better approach anyone is using.

Gary,

Use surrogate PKs that are NEVER reused and that the user NEVER sees.
Previous
Reply
Map
View

Click here to load this message in the networking platform