Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Afraid that autoincrementing integer field skips ahead
Message
From
04/09/2010 05:20:44
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
 
 
To
04/09/2010 04:06:58
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP1
Miscellaneous
Thread ID:
01479307
Message ID:
01480126
Views:
56
>>>From the response of people here, I believe my fear is irrational. The fear comes from knowing that there is no way to generate any unused values should the counter somehow skip ahead. I don't know how it would skip ahead; perhaps bug in my program(?).
>>
>>You can try to insert a record in a transaction, then rollback. My guess is that the counter would revert together with the transaction.
>
>Each time the counter changes and the value can be read in some way, will NEVER return back.

That's why I said "within a transaction" - the new value should be invisible to all until the transaction closes.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform