Skip to content

4SUC6 : "Share your goals"

You are here: Home arrow Documents

Document details

Details for Play Nice with Others: Waiting for a Lock on SAS Table
PropertyValue
NamePlay Nice with Others: Waiting for a Lock on SAS Table
Description

Multiuser access to sas data requries administration in order to avoid error messages such as "LOCK ERROR". This can be done with two strategies at least:  1. limiting access to dataset with password. 2. Setting lock on data.

1. Using sas tools, you make a specific table read-only by alter and write
protecting it. The dataset alter and write options prevent table modifications, deletions or replacements.

data nochangedoctor (alter=shhh write=secret);
  xray=1;
run;

data foo;
  set nochangedoctor;
run;

proc datasets lib=work nolist;
  modify foo (alter=xyzzy write=xyzzy);
run;

proc append base=foo(alter=xyzzy) new=foo;
run;

proc delete data=nochangedoctor(alter=shhh);
proc delete data=foo(alter=xyzzy);
run;

Use the dataset read= option to enforce a restricted access policy.
OS file attribute tools (such as unix chmod or windows cmd attrib) can also
protect the file containing a specific sas table.
libname option access=readonly can protect all tables in a library
 

2. This paper demonstrates how to use the LOCK statement in base SAS® to cause your program to wait until the tables you need are available. The techniques shown can be used to protect critical sections of code by locking multiple tables. Applying these concepts can greatly improve the reliability of programs that run in highly contentious batch environments.

FilenamePlay Nice with Others - Waiting for Lock on a SAS Table.pdf
Filesize129.1 KB
Filetypepdf (Mime Type: application/pdf)
Creatoradmin
Created On: 21.01.2008 11:14
ViewersEverybody
Maintained by
Hits275 Hits
Last updated on 21.01.2008 11:59
Homepage
 
[+]
  • Narrow screen resolution
  • Wide screen resolution
  • Auto width resolution
  • Increase font size
  • Decrease font size
  • Default font size
  • fresh color