Usage Note 56139: Creating environment variables for FILENAME PIPE for SASĀ® 9.4 in a z/OS operating environment
When you use the PIPE access method of the FILENAME statement in SAS 9.4 under z/OS, SAS creates an
unnamed pipe via BPX1PIP. The FILENAME PIPE access method creates a UNIX System Services
(USS) environment that enables the use of various USS commands. In this environment, very few environment variables are defined.
To see what environment variables are defined on the z/OS logical partition (LPAR) on which SAS 9.4 is running,
run the following code:
FILENAME USSPIPE PIPE 'env';
DATA _NULL_;
INFILE USSPIPE; /* Open the USS pipe to process USS env command */
INPUT; /* Read a record from the pipe */
PUT _INFILE_; /* Write the record to the SASLOG */
RUN;
This code can be useful if, for example, someone has a need to use the USS date command.
However, if the TIMEZONE (TZ=) environment variable is not defined or is defined incorrectly, then
the value returned from date might return an incorrect local time.
The PIPE access method of the FILENAME statement can be changed to properly define the TZ=
environment variable under USS. The following illustrates setting the TZ=
environment to EST5EDT:
FILENAME USSPIPE PIPE 'export TZ=EST5EDT; date';
DATA _NULL_;
INFILE USSPIPE;
INPUT;
PUT _INFILE_;
RUN;
There are various settings that can be provided using the TZ offset value. For example,
to set the time to 9.5 hours east of Greenwich Mean Time (GMT), one could set the value as follows:
FILENAME USSPIPE PIPE 'export TZ=EST-9:30; date';
Operating System and Release Information
| SAS System | N/A | z/OS | 9.4 TS1M0 | |
*
For software releases that are not yet generally available, the Fixed
Release is the software release in which the problem is planned to be
fixed.
| Date Modified: | 2015-07-21 13:50:26 |
| Date Created: | 2015-07-08 13:32:57 |