The LOCK Statement and the LOCK Command |
See also: | Locking SAS Data Objects |
Syntax | |
Syntax Description | |
Examples |
Syntax |
LOCK
|
specifies the name of a SAS library that is currently accessed through a SAS/SHARE server.
specifies the name of a member of the library libref that is to be locked.
specifies the type of the SAS file to be locked. Valid values are DATA, VIEW, and CATALOG. The default is DATA.
If member-type is omitted or is specified as the value DATA or VIEW, two locks are obtained: one lock on libref.member-name.DATA and the other lock on libref.member-name.VIEW.
specifies the name of the catalog entry to be locked.
specifies the type of the catalog entry to be locked.
writes to the SAS log whether the specified data object is locked and by whom. This argument is optional.
Aliases: | QUERY, SHOW |
releases a lock on the specified data object that was acquired by using the LOCK statement in your SAS session. This argument is optional.
For more information about how and when a lock is released, see Locking SAS Data Objects.
Examples |
The following LOCK command locks SAS catalog entries of type CMAP. The SAS log will show that one catalog entry has already been locked.
lock mapslib.mapscat.euromap.cmap
The following LOCK command releases the lock on the catalog entry EUROMAP.CMAP. The SAS log will show that the lock on this catalog entry has been released and by whom.
lock mapslib.mapscat.euromap.cmap clear
Copyright © 2007 by SAS Institute Inc., Cary, NC, USA. All rights reserved.