Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Increasing primary key integers in a table
Message
From
18/09/1998 17:05:45
 
 
To
18/09/1998 10:17:38
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00138182
Message ID:
00138486
Views:
16
>>Hello,
>>
>>We are using Visual FoxPro 5.0 and we are building a framework. For our tables we want to use a primary key on an 'integer'-field. Is it possible to increase the integer automaticly every time we add a new record so we will get a surrogate primary key?
>>
>
>It's standard way: you have separate table 'setup.dbf' to store tablename and next available keyvalue. When application requests new key, it goes to this table, locates appropriate table name, locks this record, picks up the leyvalue, increments it, unlocks the record and returns keyvalue.

Do you know if it is possible in Visual FoxPro 6.0 to create a surrogate primary key automaticly (autonumbering), so that there is no need to use an extra table to see what the latest number is?

Greetings,

Afier Appelman
Greetings,

Afier Appelman
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform