Previous Page | Next Page

System Options under OpenVMS

LOGPARM= System Option: OpenVMS



Controls when SAS log files are opened, closed, and, with the LOG= system option, how they are named.
Default: none
Valid in: configuration file, SAS invocation, VMS_SAS_OPTIONS DCL symbol
Category: Log and procedure output control: SAS log
PROC OPTIONS GROUP= LOGCONTROL
OpenVMS specifics: behavior of ROLLOVER=NONE; must enclose log name in quotation marks if the directive is lowercase; if OPEN= REPLACE or OPEN=REPLACEOLD, OpenVMS creates a new log using the same name but a different version number
See: LOGPARM= System Option in SAS Language Reference: Dictionary

Syntax
Details
See Also

Syntax

LOGPARM=
"<OPEN= APPEND | REPLACE | REPLACEOLD>
<ROLLOVER= AUTO | NONE | SESSION>
<WRITE= BUFFERED | IMMEDIATE>"

OPEN=

when a log already exists, controls how the contents of the existing log is treated.

APPEND

appends the log when opening an existing log. If the log does not already exist, a new log is created.

REPLACE

creates a new log using the same name with a different version number. If the log does not exist, a new log is created.

REPLACEOLD

if the log is more than one day old, creates a new log using the same name with a different version number. If the log does not exist, a new log is created. If the log is less than a day old, SAS appends the new log information to the existing log.

ROLLOVER=

controls when or if the SAS log "rolls over," that is, when the current log is closed and a new one is opened.

AUTO

causes an automatic "rollover" of the log when the directives in the value of the LOG= option change, that is, the current log is closed and a new log file is opened.

NONE

specifies that rollover does not occur, even when a change occurs in the name that is specified with the LOG= option.

Note:   Under OpenVMS, because the % symbol is not valid in a filename, you cannot specify a directive with ROLLOVER=NONE. For example, if you invoke SAS using the following code:

sas92/sysin=oranges/log=mylog%m/logparm="rollover=none"
then an error appears and the SAS job fails.  [cautionend]
SESSION

at the beginning of each SAS session, opens the log file, resolves directives that are specified in the LOG= system option, and uses its resolved value to name the new log file. During the course of the session, no rollover is performed.

WRITE=

specifies when content is written to the SAS log.

BUFFERED

writes content to the SAS log only when a buffer is full to increase efficiency.

IMMEDIATE

writes to the SAS log each time that statements are submitted that produce content for the SAS log.


Details

The LOGPARM= system option controls the opening and closing of SAS log files. This option also controls the naming of new log files, with the LOG= system option and the use of directives in the value of LOG=.

Using directives in the value of the LOG= system option enables you to control when logs are open and closed and how they are named, based on real-time events, such as time, month, day of week, and so on. For a list of directives, see LOGPARM= System Option in SAS Language Reference: Dictionary.

Some of the directives require lowercase values. By default, OpenVMS will uppercase any text that is not enclosed in quotation marks. To specify a lowercase directive, you must enclose the name of the log file in quotation marks.

For example, if you want to include the value of the current month in the name of the log file (specified by the %m directive), then you must include quotation marks around the value of LOG=:

sas92/sysin=oranges/log="mylog%m"/logparm="rollover=auto"

If you omit the quotation marks, then OpenVMS will resolve %m to %M, and the name of the log file will contain the value of the minute that the log was created rather than the month.

Note:   Under OpenVMS, you cannot specify directives using the # symbol.  [cautionend]


See Also

Previous Page | Next Page | Top of Page