Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Rlock() Weirdness
Message
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Rlock() Weirdness
Miscellaneous
Thread ID:
00255251
Message ID:
00255251
Views:
46
I have a free table (VFP6/SP3) with 4 records in it. At app startup, I want system1 to get a record lock on record1, system2 to get a record lock on record2, etc. I opened a dummy VFP session, opened the table shared, and rlock(1) at the command window to rlock for that session. Then I ran the code below on a secord VFP session, and it locks records 2 and 3. Can someone help me with my logic here? I want to limit the table to 4 records for 4 VFP sessions. Help?

clear
set reprocess to 2 automatic
if !used('safety')
use safety in 0 shared
endif
select safety
locate for rlock() = .t.
if !found()
rlock(recno())
else
continue
endif


Thanks
Next
Reply
Map
View

Click here to load this message in the networking platform