The following table summarizes the functions related to file locks.
|
|
*READ Lock |
*EXCL Lock |
*SYNC Lock |
|---|---|---|---|
|
Setting |
As *DSNR or *PGMR, perform an action that uses a file; e.g., edit an action diagram or generate source. |
Implicit: (As *DSNR) Change, add, or delete a relation. Access a panel with intent to update a file, e.g., Edit Virtual Field Entries panel. Update a field on the file. See the next section, Field Locks, for more information. |
As *DSNR, exit the model without expanding an updated file; the existing *EXCL lock is converted to a *SYNC lock. |
|
|
|
Explicit: (As *DSNR) Enter L against file on EDR1; the model does not have to be synchronized. |
|
|
Displaying |
Press F22=File Locks where available; e.g. on EDR (Edit Database Relations panel). Note: F22=File Locks displays only if the model value YOPNACC is set to *YES. |
Press F22=File Locks where available; e.g. on EDR1.
|
Press F22=File Locks where available; e.g. on EDR1.
|
|
Removing |
Exit panel where lock has been set; for example, return to Edit Database Relations. |
Implicit: (As *DSNR) Expand file; e.g., enter F, Z, E, or Q against file. Exit and resynchronize the model. If file locked as a result of a field update, finish the update. |
As *DSNR, Synchronize the model. Expand the locked file. Note: We recommend that you run the YSNCMDL command at the end of each day to synchronize the model and clear all outstanding file locks. |
|
|
|
Explicit: (As *DSNR) Enter U against file on EDR1 to unlock an explicit lock. |
|
|
Notes: |
Multiple *READ locks can exist on a file. An *EXCL lock cannot be placed on a file until all removed. |
Only one *EXCL lock can be set on a file at a time. Access path or function generation will fail if an *EXCL lock is set on the based-on file. |
A *SYNC lock is automatically converted to an *EXCL lock when any *DSNR locks the file for update. |
|
Copyright © 2014 CA.
All rights reserved.
|
|