The Work library is the temporary library
that is automatically defined by SAS at the beginning of each SAS
session or job. The Work library stores temporary SAS files that
you create, as well as files created internally by SAS.
To access files in the
Work library, specify a one-level name for the file. The libref WORK
is automatically assigned to these files unless you have assigned
the User libref.
When you invoke SAS,
it assigns the WORK libref to a subdirectory of the directory specified
in the WORK system option described in
WORK System Option: UNIX. This subdirectory is usually named
SAS_workcode_nodename
, where:
is a 12-character code.
The first four characters are randomly generated numbers. The next
eight characters are based on the hexadecimal process identification
number of the SAS session.
is the name of the
UNIX computer where the SAS process is running.
This libref cannot be cleared or reassigned during
a SAS session.
The WORKINIT and WORKTERM
system options control the creation and deletion of the Work library.
For more information,
see WORKINIT System Option in SAS System Options: Reference and
WORKTERM System Option in SAS System Options: Reference.
Note: If a SAS session is terminated
improperly (for example, with the
kill —9
command), SAS will not delete the
SAS_workcode_nodename
directory.
You might want to use
the cleanwork command to delete the directories.