Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
FLOCK() and RLOCK() differences
Message
From
12/09/2003 10:21:28
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
 
To
12/09/2003 10:17:46
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00828484
Message ID:
00828486
Views:
12
USE... EXCLUSIVE opens the file exclusively - no other user can open the table, not even for read/only.

flock() locks an entire file. If you do this, a second user can not use flock() or rlock(), but can still open the table for R/O access.

rlock() locks a single record. No other user can lock this record, until you unlock it.

>Hi,
>
>this two programs are correct ( table write-exclusive ) and equal o no ?
>
>
>RLOCK('0',myWorkArea)
>....
>UNLOCK RECORD 0 IN (myWorkArea)
>
>
>and
>
>
>FLOCK(myWorkArea)
>....
>UNLOCK RECORD 0 IN (myWorkArea)
>
>
>I can or not can open, with USE command, a table on write-exclusive mode directly?
>
>Fabio
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform