Architecting, installing and maintaining your SAS environment

SASHELP library - can this be set to readonly?

Posts: 49

SASHELP library - can this be set to readonly?


We run server-based SAS (v9.2 ... should be moving to v9.4 soon) and we occasionally experience issues with users creating static SASHELP.VCOLUMN data sets (usually by using code like PROC SORT DATA=SASHELP.VCOLUMN; BY xxxxx; RUNSmiley Wink. Obviously one thing we can do is to send out communications to our user base about this type of issue but I was wondering if it's possible to set the SASHELP libref to ACCESS=READONLY (in the config file) or would this have an impact on how SAS runs?

We use the SASHELP viewtables quite a bit (another solution is to use the dictionary tables of course) and I was wondering if setting the libref to read-only would have an impact on the functionality of these viewtables?

Super User
Super User
Posts: 6,502

Re: SASHELP library - can this be set to readonly?

Depends on your environment. If you are using a multi user environment then you would typically create whole SAS installation directory are readonly for all users and not have this problem.  Make sure to use a different account to own the files than any that you use for actually running SAS.

On a PC typically the SAS folders are setup to only be writable by administrators on the machine.

If you are an administrator on your own machine then you are at risk for this.  You might be able to take advantage of how SAS handles libraries with multiple directories.  When you write a new dataset it will always try to write it into the first directory. (use LIBNAME SASHELP LIST; to find the directories).  Typically it is the language support directory, for example C:\Program Files\SAS\SASFoundation\9.2\nls\en\SASCFG\.  So if you deny write access to that directory then any program that attempts to write to SASHELP, such as the proc sort, will fail.

Valued Guide
Posts: 3,208

Re: SASHELP library - can this be set to readonly?

The SASHELP library is in well done installation read-only. You cannot change the content of that. (normal requirement as of good practice)

You are describing the functionality of several members there acting as a program.

Is that program that inventarizes all the current open libnames and all the tables in there the build a view for you situation at that moment.

Your example eithers is indicates:

- you have a bad desinged installation where users can change that by accident    ...or...

- there is a problem with SAS as it get blocks by the OS and fails to handle that block correctly.

As the given descritpion of these fucntions they can harm expected perfromance of the system when you have many tables/libnames

---->-- ja karman --<-----
Ask a Question
Discussion stats
  • 2 replies
  • 3 in conversation