Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Which is faster?
Message
 
To
13/05/2004 19:20:28
Mike Yearwood
Toronto, Ontario, Canada
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00903686
Message ID:
00903925
Views:
23
How can a record exist in the table that has a higher value than the id table value?
Do you have other processes that are adding records without the id table?

My application is designed for multiuser environment.

It happened to one of our clients. I don't know how it happened exactly. One of the users noticed that some related information about a record wasn't correct, so they called us. I had to take their data, check and fix it. That's when I noticed the duplicate entry there. So I added a check for maximum value. According to my code, it shouldn't. I lock the record in the id table retrieve increment it and save it to a variable then unlock it. A record with a higher value in the table could exist, if somehow the saving to the id table was not successful while the record in the table was created successfully. Next time, the id is repeated. But I must say since that maximum checking was added, I haven't had one instance. Of course, that doesn't mean it won't happen.

Dawa
Dawa Tsering


"Do not let any unwholesome talk come out of your mouths,
but only what is helpful for building others up according to their needs,
that it may benefit those who listen."

- Ephesians 4:29-30 NIV

Dare to Question -- Care to Answer

Time is like water in a sponge, as long as you are willing you can always squeeze some.

--Lu Xun, Father of Modern Chinese Literature

Previous
Next
Reply
Map
View

Click here to load this message in the networking platform