Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Record lock issue
Message
From
28/08/2008 19:11:17
 
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
01342876
Message ID:
01342903
Views:
47
While LOCATE FOR will work I need to count number of records that already locked to know how many active users are in the system. The file will never be too big, I think max number of users any of our clients have is 100 right now. Also I am using FOR.. NEXT loop because in case number of locked record reached maximum number of users I want to stop checking no matter how many records are in the table.


>>>Are you sure you can use such construct here?
>>>
>>>LOCATE FOR RLOCK() sounds a bit dangerous to me.
>>
>>Dangerous? I don't think so. Non-intuitive, perhaps.
>>
>>While looking for a record that matches the condition, VFP will try to lock each record!
>>
>>I tried it some time ago, and it worked.
>
>Yes, I understand that it would try to lock each record. Did you test speed wise LOCATE FOR RLOCK() vs. SCAN IF RLOCK() on a big table?
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform