This option is used to lock, unlock, or display locked files.
Files can be locked or unlocked for all users or for all but utility/EXF users. Once locked for all users, a file cannot be unlocked for utility users only.
Locking is immediate: a transaction in process whose file becomes locked will be backed out.
Unlocking makes the file available again for normal use.
Equivalent direct commands are
LOCK FILE
UNLOCK FILE
Selecting option "L" (Lock/Unlock Files) from the Session Opercoms menu displays the following:
10:12:10 ***** A D A B A S BASIC SERVICES ***** 2005-11-24 - Lock / Unlock Files - PACIL02 Code Service ---- ---------------------------------- D Display locked files F Lock file for all users K Advance lock file L Lock file except for UTI/EXF users N Unlock file from general lock R Release an advance lock U Unlock file from UTI/EXF lock ? Help . Exit ---- ----------------------------------- Code ......... _ File Number .. 30 UTI/EXF Ind .. U Database ID .. 105 (RD-105) Command ==> PF1----- PF2------ PF3------ PF4------ PF6----- PF7----- PF8----- PF12----- Help Exit Menu |
To list and modify the files that are locked
Enter "D" in the Code field and press ENTER.
Note:
You can unlock a file directly from the Lock / Unlock Files menu by
entering an "N" or "U"
function.
The Display Locked Files screen is displayed:
10:17:45 ***** A D A B A S BASIC SERVICES ***** 2005-11-24 DBID 105 - Display Locked Files - PACID02 Mark entries with 'U' to unlock: M Fnr. Lock Status M Fnr. Lock Status - ----- ------------------------- - ----- ------------------------- _ 1 Locked for ALL users _ 35 Locked except for UTI _ 50 Locked except for EXU/EXF _ 55 Locked for ALL users _ 60 Locked for ALL users PF1----- PF2------ PF3------ PF4------ PF6----- PF7----- PF8----- PF12----- Help Exit -- - + Menu |
To unlock files
Enter a "U" in the M column to the left of the file number on this screen.
Multiple files may be unlocked at the same time.