Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How would you do this?
Message
From
05/11/1999 10:25:20
 
General information
Forum:
Visual FoxPro
Category:
Client/server
Miscellaneous
Thread ID:
00287031
Message ID:
00287517
Views:
33
>Hi Bob,
>
>Can you please expand a little on your semaphore locking scheme idea. One of the things I thought of was like this but one stumbling block was, what if a user had a record flagged as locked and then suffered some sort of computer crash? The flag would still exist?

Yep... it would. You could either implement a timeout feature, or provide a method for an admin person to reset the flag, or delete the sephamore... Also, wouldn't the same user go back into the record to continue what they were doing.

You could also have something at the beginning of your ap startup that deleted all sephamores for that user when they connected.

Of course, another thing you could do is use Record Locking... which is supported in SQL 7.0, but not all other back ends.

Another thing you could do is start a transaction when the user went into edit mode.

But, I think a sephamore table would be the best idea. The possobility of a user crashing after putting a sephamore in the table is small and something you can deal with.

BOb
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform