Resources

The SAS System for CMS: What's New in Version 8

Output Delivery System | External I/O | SAS I/O | Tuning | Date and Time Processing | DATA Step | Windowing Environment | SAS/CONNECT | SAS/SHARE | Help and Documentation

Output Delivery System

In earlier versions of SAS, printed output from SAS procedures and from the DATA step was designed for a traditional line-printer. In Version 8, printed output is much more flexible. The new Output Delivery System (ODS) enhances your ability to manage both DATA step and procedure output. ODS features include the ability to:

ODS provides a flexible mechanism for procedures to produce output. Instead of writing to the listing file directly, the procedure creates an output object for each piece of output to be displayed. Every table, plot, and chart is thus a separate entity in the system. Each output object is composed of a data component (the collection of raw numbers and characters comprising the contents of the output) and a template component (the description of what the output is supposed to look like when the data is formatted and arranged on a page).

Output objects are created by the procedure, and they are rendered based on the output destinations that the user has requested. You can control which output destinations are in effect by using the ODS statement or by selecting output destinations in the SAS Explorer. The Results window retains a running record of the output directory hierarchy that is produced when a SAS job is executed. The items on the left-hand side of the RESULTS node are output directories. The items on the right-hand side of the RESULTS node are pieces of output.

ODS currently supports four destinations: the HTML destination (for output that is written in Hypertext Markup Language), the Output destination (for creating a SAS data set), the Printer destination (for output that is formatted for a high-resolution printer), and the Listing destination. ODS destinations can be open or closed. When a destination is open, ODS can send output objects to it. Multiple output destinations can be active at the same time. You open and close a destination with the appropriate ODS statement (ODS HTML, ODS LISTING, ODS PRINTER, or ODS OUTPUT). By default, the Listing destination is open, and all other destinations are closed. Consequently, if you do nothing, your SAS programs run and produce Listing output, just as they did in earlier releases of the SAS System.

By default, ODS output is formatted according to instructions in various definitions that the procedure or DATA step points to. However, ODS provides ways for you to customize the output. You can customize the output for an entire SAS job, or you can customize the output for a single output object. To customize the presentation aspects of the output at the level of the entire SAS job, use a style definition. To customize the output for a single output object, use a table definition. The TEMPLATE procedure creates and modifies these definitions, which the Output Delivery System then uses to create formatted output.

ODS styles govern the overall look and feel of SAS procedure output. Styles determine the colors, fonts, graphic images, and other visual aspects in effect when output is generated. SAS delivers several predefined styles, and you can customize them or create new ones.

Exactly one style is in effect at any time during a SAS session. It applies to all procedure output during the period it is in effect. This gives the output a uniform look and feel. Regardless of the procedure, row headers have the same background color, data cells have the same font, and so forth.

A style definition describes how to render the presentation aspects (color, font face, font size, and so forth) of an entire SAS job. Each style definition is composed of style elements, where a style element is a collection of style attributes that apply to a particular part of the output. For instance, a style element may contain instructions for the presentation of column headers or for the presentation of the data inside cells. Style elements may also specify default colors and fonts for output that uses the style definition. Each style attribute specifies a value for one aspect of the presentation. For instance, the BACKGROUND= attribute specifies the color for the background of an HTML table, and the FONT_STYLE= attribute specifies whether to use a Roman, a slant, or an italic font.

A table definition describes how to render the output for a tabular output object. (Almost all ODS output is tabular.) A table definition determines the order of table headers and footers, the order of columns, and the overall look of the output object that uses it. Each table definition contains or references table elements, where a table element is a collection of attributes that apply to a particular column, header, or footer. Typically, these attributes specify something about the data rather than about its presentation. For instance FORMAT= specifies the SAS format to use in a column. However, some attributes describe presentation aspects of the data.

Both style definitions and table definitions are contained in templates. SAS System templates are stored in the SASHELP library. When you run PROC TEMPLATE to modify or edit a template, the template is stored in the SASUSER library. You can modify the concatenation path that ODS uses to look up templates with the ODS PATH statement. This enables you to set up a default set of templates for your organization to give your SAS output a look and feel consistent with your organization's needs.

Although primarily created for procedure output, this new functionality is also available for DATA step programs, through the FILE and PUT statements. The FILE statement is used to define an ODS output object using the new ODS= option. With this new FILE statement option, the template is specified, and an ODS object is defined and created. Data columns for the data object are specified, and mapped to variables in the DATA step program data vector. The PUT statement can then be used to move data from these DATA step variables into the ODS output object. For a complete discussion of the DATA step interface to ODS, see the SUGI 23 paper "ODS: The DATA Step Knows".

For more information on the Output Delivery System, see The Complete Guide to the SAS Output Delivery System, Version 8.

External I/O Enhancements

Catalog Access Method
Email Access Method
FTP Access Method
PIPE Access Method
Socket Access Method
URL Access Method
External I/O: Functions
External I/O: Statements

External I/O: CATALOG Access Method

With the CATALOG access method you can reference a SAS catalog or an entry within a SAS catalog as an external file. You can then use any SAS commands, statements or procedures that access external files to access catalogs. With the CATALOG access method you can read any type of catalog entry, but you can only write to entries of type LOG, OUTPUT, SOURCE, and CATAMS.

Some new capabilities this offers are:

For more information about the CATALOG access method, including examples that illustrate the way it can be used, see SAS Language Reference: Dictionary, Version 8.

External I/O: EMAIL Access Method

As an experimental feature in Version 8, the SAS System enables you to send electronic mail (e-mail) from a DATA step, SAS procedure, or SCL. Specifically, you can:

The SAS System sends all e-mail over a socket to an SMTP server.

Note:   You or your system administrator may have to specify the EMAILHOST and EMAILPORT SAS system options. The EMAILHOST option identifies the host that runs the SMTP server on your network. It defaults to localhost. The EMAILPORT option identifies the port number for the SMTP server. It defaults to 25.

Using the DATA Step or SCL to Send E-mail

In general, a DATA step or SCL code that sends e-mail has these components:

Options that you specify in the FILE statement override any corresponding options that you specified in the FILENAME statement.

In your DATA step, after using the FILE statement to define your e-mail fileref as the output destination, use PUT statements to define the body of the message.

You can also use PUT statements to specify e-mail directives that change the attributes of your electronic message or perform actions with it.

Sending Procedure Output as E-mail

E-mail can also be used to send procedure output. Two of the ways you can use this feature are directing HTML procedure output generated using ODS and sending images generated by graphics procedures.

ODS HTML procedure output must be sent with the RECORD_SEPARATOR (RS) option set to NONE. For CMS, ODS produces an HTML stream with embedded record-separator characters, by default. When the RS option is set to NONE, ODS writes one line of HTML at a time to the file.

Further Information about EMAIL Access Method

For more information abou the EMAIL Access Method, including examples that illustrate the way it can be used, see SAS Companion for the CMS Environment, Version 8.

External I/O: FTP Access Method

With the FTP access method you can use file transfer protocol (FTP) to read or write to a file from any host machine that you can connect to on a network with an FTP server running. Use this access method when you want to connect to the host machine, log in to the FTP server, to make records in the specified file available for reading or writing, and then to disconnect from the host machine.

Some of the types of tasks you can perform using the FTP access method are:

For more information about the FTP access method, including examples that illustrate the way it can be used, see SAS Language Reference: Dictionary, Version 8.

External I/O: Pipe Access Method

The PIPE access method allows you to pipe data between SAS and CMS Pipelines.

The pipe can be opened for input or output. When a pipe is opened for input by the INFILE statement, output from the pipe is available for input. When a pipe is opened for output by the FILE statement, any lines that are written to the pipe by the PUT statement are input to the pipe.

For more information about the PIPE access method, including examples that illustrate the way it can be used, see SAS Companion for the CMS Environment, Version 8.

External I/O: Socket Access Method

The socket access method enables you to read from or write to a Transmission Control Protocol/Internet Protocol (TCP/IP) socket. A TCP/IP socket is a communication link between two applications. The server application creates the socket and waits for a connection. The client application connects to the socket. With the SOCKET access method, you can use SAS to communicate with another application over a socket in either client or server mode. The client and server applications can reside on the same machine or on different machines that are connected by a network.

You can use the SOCKET access method in either client mode or server mode. In client mode, a local SAS application can use the SOCKET access method to communicate with a remote application that acts as a server (and waits for a connection). When the local SAS application is in server mode, it remains in a wait state until a remote application connects to it. To use the SOCKET access method in server mode, you need to know only the port number that you want the server to listen to for a connection.

For more details about the SOCKET access method, including an example that illustrates the way it can be used, see SAS Language Reference: Dictionary, Version 8.

External I/O: URL Access Method

With the URL access method you can read a file from any host machine that you can connect to on a network with a URL server running.

Among the capabilities the URL access method offers are:

For more details about the URL access method, including examples that illustrate the features mentioned above, see SAS Language Reference: Dictionary, Version 8.

External I/O: Functions

These external file I/O functions are new:
DCLOSE
closes a directory.
DINFO
returns information about a directory.
DNUM
returns the number of members in a directory.
DOPEN
opens a directory.
DOPTNAME
returns directory attribute information.
DOPTNUM
returns the number of information items available for a directory.
DREAD
returns the name of a directory member.
FAPPEND
appends the current record to the end of an external file.
FCLOSE
closes an external file, directory, or directory member.
FCOL
returns the current column position in the File Data Buffer (FDB).
FDELETE
deletes an external file.
FEXIST
verifies the existence of an external file that is associated with a fileref.
FGET
copies data from the File Data Buffer (FDB) into a variable.
FILEEXIST
verifies the existence of an external file by its physical name.
FILENAME
assigns or deassigns a fileref for an external file, directory, or output device.
FILEREF
verifies that a fileref has been assigned for the current SAS session.
FINFO
returns a file information item.
FNOTE
identifies the last record that was read.
FOPEN
opens an external file.
FOPTNAME
returns the name of an item of information about a file.
FOPTNUM
returns the number of information items that are available about an external file.
FPOINT
positions the read pointer on the next record to be read.
FPOS
sets the position of the column pointer in the File Data Buffer (FDB).
FPUT
moves data to the File Data Buffer (FDB) of an external file starting at the FDB's current column position.
FREAD
reads a record from an external file into the File Data Buffer (FDB).
FREWIND
positions the file pointer at the start of the file.
FRLEN
returns the size of the last record read, or, if the file is opened for output, returns the current record size.
FSEP
sets the token delimiters for the FGET function.
FWRITE
writes a record to an external file.
MOPEN
opens a file by directory ID and member name.
PATHNAME
returns the physical name of a SAS data library or an external file.

External I/O: Statements

SAS I/O Enhancements

Long Variable Names and Expanded Rules for SAS Names
Logical Concatenation of SAS Libraries
Logical Concatenation of SAS Catalogs
Generation Data Sets
Integrity Constraints
Indexing Enhancements
Enhancements for Compressed Files
Audit Trail
Functions
Statements
Compatibility Issues

SAS I/O: Long Variable Names and Expanded Rules for SAS Names

The rules for SAS names have been expanded to provide more functionality. Some SAS names, such as DATA step variables, members of SAS data libraries, and catalog entries, can be up to 32 bytes long. A variable name can be mixed case.

In a DATA step or a PROC SQL step, you can more easily use DBMS files. You can use a new name literal to express a DBMS column name that may contain characters that are not normally allowed in SAS names. The SAS system option VALIDVARNAME= enables you to specify what rules apply to the variable names that you can create and process in a SAS session.

SAS I/O: Logical Concatenation of SAS Libraries

You can now reference two or more SAS libraries with a single libref in all operating environments. To make your code easier to use in multiple operating environments, you can use a libref, rather than only the physical name as in Version 6, to specify the aggregate storage location that contains your SAS files.

SAS I/O: Logical Concatenation of SAS Catalogs

You can now logically concatenate entries in two or more SAS catalogs. Use the LIBNAME statement to implicitly concatenate entries in SAS catalogs. Use the new CATNAME statement to explicitly concatenate entries in SAS catalogs.

SAS I/O: Generation Data Sets

Generation data sets enable you to keep multiple copies of a SAS data set. The copies represent versions of the same data set, which is archived each time it is replaced. To request generation data sets, use the GENMAX= data set option. To reference a specific version of a data set, use the GENNUM= data set option.

SAS I/O: Integrity Constraints

Integrity constraints enable you to specify rules that guarantee the consistency and correctness of stored data. The rules restrict the data that can be added, updated, or deleted from a data set, and they also link the data in one data set to data in another data set.

You can specify integrity constraints either when a data set is created or after it already contains data. To create and delete integrity constraints, you can use the DATASETS procedure, the SQL procedure, or SCL functions. To list integrity constraints, use the CONTENTS procedure.

SAS I/O: Indexing Enhancements

Version 8 incorporates the following performance improvements for indexed data sets:

SAS I/O: Enhancements for Compressed Files

Compressed data sets are more flexible to use. You can now access observations in a compressed SAS data set directly by using the POINT= or FIRSTOBS= option.

You can choose a compression algorithm that best fits your data. For compressing character data, specify CHAR to use the RLE (Run Length Encoding) algorithm. For compressing binary (for example, numeric) data, specify BINARY to use the RDC (Ross Data Compression) algorithm.

In Version 8, you can use the POINTOBS= data set option to control whether a compressed data set may be processed with random access rather than with sequential access only.

SAS I/O: Audit Trail

An audit trail enables you to log updates to a SAS data file in a separate audit file. Each time an observation is added, deleted, or updated, information is added to the audit file about who made the modification, what was modified, and when.

You can also define special variables that are stored in the audit file. The user can assign values to them just like regular data set variables. They are stored with each record written to the audit trail. For example, they could be used to log a "reason for modification."

The audit trail is initiated with the AUDIT statement in PROC DATASETS. See SAS Procedures Guide, Version 8 for more information.

SAS I/O: Functions

The following new functions are for libraries and catalogs:
CEXIST
verifies the existence of a SAS catalog or SAS catalog entry and returns a value.
LIBNAME
assigns or deassigns a libref for a SAS data library and returns a value.
LIBREF
verifies that a libref has been assigned and returns a value.
The following CALL routine is new:
CALL SET
links SAS data set variables to DATA step or macro variables of the same name and data type.
These data set I/O functions are new:
ATTRC
returns the value of a character attribute for a SAS data set.
ATTRN
returns the value of a numeric attribute for a SAS data set.
CLOSE
closes a SAS data set.
CUROBS
returns the observation number of the current observation.
DROPNOTE
deletes a note marker from a SAS data set or an external file.
DSNAME
returns the data set name that is associated with a data set identifier.
EXIST
verifies the existence of a SAS data library member.
FETCH
reads the next nondeleted observation from a SAS data set into the Data Set Data Vector (DDV).
FETCHOBS
reads a specified observation from a SAS data set into the Data Set Data Vector (DDV).
NOTE
returns an observation ID for the current observation of a SAS data set.
OPEN
opens a SAS data set.
POINT
locates an observation that is identified by the NOTE function.
REWIND
positions the data set pointer at the beginning of a SAS data set.
These new functions return information about variables:
GETVARC
returns the value of a SAS data set character variable.
GETVARN
returns the value of a SAS data set numeric variable.
VARFMT
returns the format that is assigned to a SAS data set variable.
VARINFMT
returns the informat that is assigned to a SAS data set variable.
VARLABEL
returns the label that is assigned to a SAS data set variable.
VARLEN
returns the length of a SAS data set variable.
VARNAME
returns the name of a SAS data set variable.
VARNUM
returns the number of a SAS data set variable's position in a SAS data set.
VARTYPE
returns the data type of a SAS data set variable.
The following functions return information about the attributes of variables. The functions with names that end in an "X" can accept an expression as an argument; the others require a variable name as an argument:
VNAME, VNAMEX
returns the name of the given variable.
VLABEL, VLABELX
returns the label associated with the given variable, or the variable name if there is no label.
VTYPE, VTYPEX
returns the type of the given variable ('N' for numeric and 'C' for character).
VLENGTH, VLENGTHX
returns the defined compile-time size of the given variable.
VFORMAT, VFORMATX
returns the format associated with the given.
variable (for example, $CHAR20.)
VFORMATN, VFORMATNX
returns the format name, excluding any lengths, associated with the given variable (for example, $CHAR).
VFORMATW, VFORMATWX
returns the format width value (w) associated with the given variable.
VFORMATD, VFORMATDX
returns the format decimal value (d) associated with the given variable.
VINFORMAT, VINFORMATX
returns the informat associated with the given variable (for example, $CHAR20.).
VINFORMATN, VINFORMATNX
returns the informat name, excluding any lengths, associated with the given variable ($CHAR).
VINFORMATW, VINFORMATWX
returns the informat width value (w) associated with the given variable.
VINFORMATD, VINFORMATDX
returns the informat decimal value (d) associated with the given variable.
VARRAY, VARRAYX
returns 1.0 if the given variable denotes an array name, and 0.0 if it does not.
VINARRAY, VINARRAYX
returns 1.0 if the given variable is an element of any array, and 0.0 if it is not.

SAS I/O: Statements

SAS I/O: Referencing a Permanent SAS Data Set Without a Libref

You can create or reference a permanent SAS data set without first assigning a libref. You can refer to a SAS data set directly by specifying in quotes the name by which the operating system refers to the file.

SAS I/O: Compatibility Issues

Date and Time Processing: Formats

The following formats are new:

DATEAMPMw.d
writes datetime values (ddmmmyy:hh:mm:ss.ss) with AM or PM.
DDMMYYxw.
writes date values in the form ddmmyy or ddmmyyyy and specifies separators or no separators between date values.
MMDDYYxw.
writes date values in the form mmddyy or mmddyyyy and specifies separators or no separators between date values.
PDJULGw.
writes packed Julian date values in the hexadecimal format yyyydddF for IBM.
PDJULIw.
writes packed Julian date values in the hexadecimal format ccyydddF for IBM.
TIMEAMPMw.d
writes hours, minutes, and seconds with AM or PM.
YYMMDDxw.
writes date values in the form yymmdd or yyyymmdd and specifies separators or no separators between date values.

Date and Time Processing: Informats

The DATEJUL informat can be used to read Julian dates in either yyddd or yyyyddd format. If the date is in yyddd format, then SAS uses the value of the YEARCUTOFF= SAS system option to interpret yy.

Creation date and date last modified are stored in ISPF statistics in directory entry in 0CYYDDDF packed format, where C= 0 for 1900, 1 for 2000, etc. Consider, for example, x'0090045F'. The century is 0, corresponding to 1900. The year is 90. The day is 45, corresponding to 02/14. The resolved date in mm/dd/yyyy format is 02/14/1990.

The following informats are new:

JDATEYMD
reads Japanese kanji date values in the format yymmmdd or yyyymmmdd.
JNENGO
reads Japanese Kanji date values in the form yymmdd.
PDJULGw.
reads packed Julian date values that are produced on IBM mainframe systems in the hex representation form of yyyydddF. and converts the values to SAS date values.
PDJULIw.
reads packed Julian date values that are produced on IBM mainframe systems in the form ccyyddF. and converts the values to SAS date values.
SHRSTAMP.w
reads date and time values of SHR records.
YYMMNw.
reads date values that are in the form yymm or yyyymm and that contain no delimiters, then adds a date value of 01 so that these values become valid SAS date values.

Date and Time Processing: Functions

These date and time functions are new:

DATDIF
returns the number of days between two dates.
JULDATE7
returns a seven digit Julian date from a SAS date value.
YRDIF
returns the difference in years between two dates.

DATA Step: Long Variable Names and Values

The maximum length for many SAS names has been increased to 32 (from 8 in earlier versions). In the DATA step, variable names (including array names), window names, and statement labels may now consist of up to 32 characters. A variable name can be mixed case.

There also has been an increase in length of value that could be contained in a character variable. In earlier releases the limit was 200, now it is 32,767.

DATA Step: Reporting

Reports that are created with the FILE and PUT statements in a DATA step have two new features:

DATA Step: External I/O Buffer Access

The ability to directly access input and output buffers has been enhanced.

Instead of just referencing the _INFILE_ pseudo-variable in a PUT statement, you may now use it almost anywhere a variable reference may occur, including as the source or target in an assignment statement, or as a function call argument.

A new pseudo-variable _FILE_ offers you access to the current output buffer, the last buffer formatted by the most recent PUT statement. You may access the _FILE_ pseudo-variable before or after the PUT statement executes. Before the PUT statement executes, the output buffer is empty. At this point, you may want to initialize the buffer with some data that would be reflected in the next PUT statement. You may also access the _FILE_ variable after a PUT statement executes, provided that the buffers are held in memory, either by using a trailing @ or N= and # line pointer controls.

DATA Step: Stored Compiled Programs and DATA Step Views

In Version 8, SAS no longer requires that you recompile stored compiled DATA step programs or recreate DATA step views that were created in previous versions or releases of SAS. Stored programs and views created in Version 6 or Version 7 run as is in Version 8, provided that you run them on the same operating system on which they were created.

By default, SAS also saves the source statements when you create stored compiled programs and DATA step views in Version 8. You can retrieve and/or execute the statements by using the new DESCRIBE and EXECUTE statements within the DATA step.

DATA Step: Statements

There are two new statements:
DESCRIBE
retrieves source code from a stored compiled DATA step program or a DATA step view and writes it to the SAS log. It is used within a DATA step with the DATA statement's PGM= or VIEW= options.
EXECUTE
executes a stored compiled DATA step program. It is used within a DATA step with the DATA statement's PGM= option.
Enhancements to statements include the following:

DATA Step: Formats

Changes to formats include the following:

The following formats are new:

IBRw.d
writes integer binary (fixed-point) values in Intel and DEC format.
NUMXw.d
writes numeric values with a comma for the decimal point.
PIBRw.d
writes positive integer binary (fixed-point) values in Intel and DEC formats.

DATA Step: Informats

Character informats can handle strings up to 32,767 characters (32K) long.

The following informats are new:

IBRw.d
reads integer binary (fixed-point) values in Intel and DEC format.
NUMXw.d
reads numeric values in which a comma marks the decimal place. in the hex representation form of yyyydddF. and converts the values to SAS date values.
PIBRw.d
reads positive integer binary (fixed-point) values in Intel and DEC formats.

DATA Step: Functions and CALL Routines

In addition to the functions described below see also External I/O: Functions, SAS I/O: Functions, and Date and Time Processing: Functions.

Mathematical and Probability Functions

The following mathematical and probability functions have been added to base SAS software:

CDF
computes cumulative distribution functions.
COMB
computes the number of combinations of n elements taken r at a time and returns a value.
CONSTANT
computes some machine and mathematical constants and returns a value.
DEVIANCE
computes the deviance and returns a value.
FACT
computes a factorial and returns a value.
LOGPDF | LOGPMF
computes the logarithm of a probability (mass) function.
LOGSDF
computes the logarithm of a survival function.
PDF | PMF
computes probability density (mass) functions.
PERM
computes the number of permutations of n elements taken r at a time and returns a value.
PROBBNRM
computes a probability from the bivariate normal distribution and returns a value.
PROBMC
computes a probability or a quantile from various distributions for multiple comparisons of means and returns a value.
SDF
computes a survival function.

Financial Functions

In Version 8, the following financial functions have been added to base SAS software:
CONVX
returns the convexity for an enumerated cashflow.
CONVXP
returns the convexity for a periodic cashflow stream, such as a bond.
DUR
returns the modified duration for an enumerated cashflow.
DURP
returns the modified duration for a periodic cashflow stream, such as a bond.
PVP
returns the present value for a periodic cashflow stream, such as a bond.
YIELDP
returns the yield-to-maturity for a periodic cashflow stream, such as a bond.

String Matching Functions

The following new functions and CALL routines provide character-string matching functionality. That is, they enable you to search for (and, optionally, to replace) patterns or characters in a string.
CALL RXCHANGE
changes one or more substrings that match a pattern.
CALL RXFREE
frees memory that is allocated by other regular expression (RX) functions and CALL routines.
CALL RXSUBSTR
finds the position, length, and score of a substring that matches a pattern.
RXMATCH
finds the beginning of a substring that matches a pattern and returns a value.
RXPARSE
parses a pattern and returns a value.
SPEDIS
returns the likelihood of two words matching, expressed as the asymmetric spelling distance between two words.

Web-based Functions

The following web-based functions have been added to base SAS software:

HTMLDECODE
decodes a string containing HTML numeric character references or HTML character entity references and returns the decoded string.
HTMLENCODE
encodes characters using HTML character entity references and returns the encoded string.
URLDECODE
returns a string that was decoded using the URL escape syntax.
URLENCODE
returns a string that was encoded using the URL escape syntax.

General Functions

The following general functions are also new:
GETOPTION
returns the value of a SAS system option or graphics option.
IORCMSG
returns a formatted error message for _IORC_.
MISSING
returns a numeric result that indicates whether the argument contains a missing value.
SYSGET
returns the value of the specified operating environment variable.
SYSMSG
returns the text of error messages or warning messages from the last data set or external file function execution.
SYSRC
returns a system error number.

Windowing Environment: SAS Explorer Window

The SAS workspace is composed of windows that enable you to accomplish specific tasks. Along with the main programming windows (Program Editor, Log, and Output), the workspace now includes SAS Explorer, a central point for managing basic SAS software tasks such as:

If you issue the CAT, DIR, LIB, or FILENAME commands, an Explorer window opens. For example, if you type CAT WORK.TEST, you will see the contents of your TEST catalog in a modified Explorer window.

Windowing Environment: SAS Registry Editor

The SAS Registry stores configuration data about the SAS session and about various applications. You can use the SAS Registry Editor window to

You can also use PROC REGISTRY to accomplish these tasks.

Windowing Environment: Results Window

The Results window contains pointers to various locations in the Output window. When procedure code executes, pointers to specific output are generated and are listed in the Results window. You can click the navigation pointers to locate the desired output.

SAS/CONNECT: Asynchronous Remote Submits

SAS/CONNECT now supports both synchronous and asynchronous remote processing. In Version 6, only synchronous processing was supported. With synchronous processing, the default behavior, you wait for the results of the remote processing before you are able to continue local processing. With asynchronous processing, you immediately regain control to continue local processing while the remote job executes, and results can be obtained at a later time.

The ability to execute remote submits asynchronously allows you to continue processing on your local host while the remote submit executes in the background. Asynchronous processing provides increased time effieiency by allowing you to perform multiple tasks simultaneously. Using this technique, you can start a long running task in the background on a remote host, and immediately be able to begin another task on another remote host or continue local processing, rather than wait until the first remote task is complete before regaining control of your local SAS session. This also provides you with flexibility as to when and where tasks are performed.

The following new statements are available for checking the status of asynchronous remote processing and obtaining results from it:

RDISPLAY
creates windows for the log and output from an asynchronous remote submit.
RGET
retrieves the log and output from an asynchronous remote submit and merges them with the local session.
New options have also been added to the SIGNON, the SIGNOFF and the RSUBMIT statements to support asynchronous processing. The following options help control access to and execution on the remote host:
CONNECTREMOTE=
identifies which remote session to connect to.
CONNECTSTATUS=
indicates whether the status window will be displayed during a file transfer.
CONNECTWAIT=
specifies whether a remote submit is processed synchronously or asynchronously.
CMACVAR=
identifies the name of a macro variable to associate with a remote submit.
CSCRIPT=
specifies a script file to use during SIGNON and SIGNOFF.
CSYSRPUTSYNC=
forces the macro variables for an asynchronous remote submit to be defined as soon as %SYSRPUT executes rather than at a synchronization point.

For more information refer to SAS/CONNECT User's Guide, Version 8 or "New V7 Client/Server Capabilities to Solve and Secure Your Distributed Processing Needs" by Cheryl Garner.

SAS/CONNECT: Output Delivery System Support

When using compute services in SAS/CONNECT software, you can use the Output Delivery System (ODS) to change the format and appearance of SAS output that is generated on a remote host. You can generate ODS output from a remote host when using either a synchronous or an asynchronous remote submit. ODS statements and procedures that support ODS can be used to

SAS/CONNECT: Encryption Services

Encryption services protect data that is sent between hosts across a network. Encryption services use a reversible algorithm to convert plain-text data into an unintelligible form, thus protecting data from being used by unauthorized parties. A SAS proprietary form of data encryption is available on all platforms.

Encryption services are packaged in two forms because of export key-length restrictions:

The North American version is available to North American customers and certain other customers by special export license. It supports strong encryption, 1024-bit or 512-bit RSA keys in combination with the following algorithms: The International version is available to International customers and supports two types of encryption: Encryption is specified by the following SAS options:
NETENCRYPTALGORITHM
specifies the encryption algorithm.
NETENCRYPT
specifies the requirement to operate in encryption mode; for example, both the client and the server sessions must be operating in encryption mode.
NETENCRYPTKEYLEN
specifies the key length, 40-bits or 128-bits, to be used by the encryption algorithm.
NETMAC
controls the use of Message Authentication Codes (MACs) on network communications. A MAC is the equivalent of a checksum that is used to ensure that the original message has not been modified.

For more information on data encryption, refer to the Appendix, "Encryption Services" in SAS/CONNECT User's Guide, Version 8, and "New V7 Client/Server Capabilities to Solve and Secure Your Distributed Processing Needs" by Cheryl Garner.

SAS/CONNECT: Messaging Services

SAS/CONNECT offers the ability to design and develop distributed applications that communicate by using messages. Messaging services enable the programs that compose a distributed application to communicate by sending data in the form of a message. Two forms of messaging services are available: direct messaging and indirect messaging. Both direct and indirect messaging enable you to include attachments with messages that are sent between a client and a server portion of an application.

Messaging allows applications to communicate by sending each other data in messages. Any action can be taken upon receipt of a message and acknowledgements can be returned to the sender if and when appropriate. With direct messaging, both the client and the server must be active at the same time. With indirect messaging, this restriction is lifted.

Messaging enables application developers to deploy multi-tiered distributed applications. This multi-tiered design allows you to separate and centralize business and data access to the server portion of the application. You can then implement a thin client application that requires little or no maintenance. Not only is it easy to segment your logic into individual programs, but these programs can execute on the host that best meets your data and resource requirements.

The indirect messaging facility allows you to write applications that communicate asynchronously with each other. That is, one application could send messages to one or more target applications that may not be currently running and that may not run for several more hours or days. SAS indirect messaging (message queueing) enables programs to communicate indirectly by placing messages on queues in storage. Therefore, the pieces of your application can run independently of each other, can run at different speeds and times, and can run without a direct connection between them.

SAS/CONNECT User's Guide, Version 8 contains more information about messaging services.

SAS/CONNECT: Cross-Environment Data Access (CEDA)

SAS software introduces a new cross-environment data access (CEDA) facility. SAS recognizes that diverse and distributed computers have become more common than they were when Version 6 was introduced. It is no longer unusual to have a site where multiple CPUs share access to a single disk or to a single networked file system. With CEDA, SAS data sets are accessible across platforms. CEDA allows any SAS data set that is created on a directory-based host to be read by a SAS session that is running on another directory-based host. This means that from UNIX System Services on OS/390 you can access SAS data sets on Windows NT, Windows 95, Windows 98, OS/2, Macintosh, Solaris, HP-UX, RS/6000, AIX, Compaq Tru64 UNIX (formerly Compaq's DIGITAL UNIX), OpenVMS Alpha, and OpenVMS VAX.

The advantage of CEDA is that you can transfer your data sets from one host to another, or NFS mount a disk from another host and automatically be able to access your data without any extra steps. CEDA eliminates the need to execute any other procedure, maintain a running server, or even SIGNON to the remote host.

For more information about CEDA, see SAS/CONNECT User's Guide, Version 8 or "New V7 Client/Server Capabilities to Solve and Secure Your Distributed Processing Needs" by Cheryl Garner.

SAS/SHARE: Version 8 and Version 6 Are Compatible

Version 8 and Version 6 SAS/SHARE client/server applications are compatible. This enables you to convert your applications incrementally rather than at one time. For example, you can convert your client from Version 6 to Version 8 and still communicate with a Version 6 server. After successfully converting the client, the server can then be converted. Another approach would be to convert the server first and then the client. Otherwise, both client and server would need to be converted simultaneously, which generally increases the cost and risk of the conversion.

SAS/SHARE: Data Encryption

Encryption services protect data that is sent between hosts across a network. Encryption services use a reversible algorithm to convert plain-text data into an unintelligible form, thus protecting data from being used by unauthorized parties. For the OS/390 platform, the purchase of a license for SAS/SECURE is necessary. SAS/SECURE provides access to the encryption services of the RSA BSAFE Crypto-C Toolkit.

In Version 8, SAS/SECURE introduces support for the RSA BSAFE Crypto-J Toolkit for Java clients of the SAS server. SAS system options for data encryption for the RSA BSAFE Crypto-C Toolkit and the Microsoft CryptoAPI (for Windows) are:

NETENCRYPT
specifies the requirement to operate in encryption mode; for example, both the client and the server sessions must be operating in encryption mode.
NETENCRYPTALGORITHM
specifies one or more encryption algorithms to use in a SAS/SHARE client/server session.
NETENCRYPTKEYLEN
specifies the key length, 40-bits or 128-bits, to be used by the encryption algorithm.
NETMAC
controls the use of Message Authentication Codes (MACs) on network communications. A MAC is the equivalent of a checksum that is used to ensure that the original message has not been modified.

Other documentation explains options that are applicable to RSA BSAFE Crypto-J Toolkit Java clients.

Documentation: Using Online Help

In the windowing environment, extensive help is available through the SAS online Help. To access online Help, either enter the HELP command or issue the PMENU command as needed to display SAS menus, then select

     Help->SAS System Help

This causes the HELP Browser window to display. Then select Help topics of interest at increasing levels of detail.

Underlined text in the Help Browser window represents links to additional information. You can use the Tab key to move the cursor from link to link in the current window. To display the linked topic, position the cursor on the underlined text for the desired link and press Enter or click the left mouse button.

The Help Browser keeps a history of the help topics you view. The following navigation controls are available:

Menu: View -> Backward or Command: HB[ACKWARD] or PFKey: 11
displays the previous help topic in the history sequence
Menu: View -> Forward or Command: HF[ORWARD] or PFKey: 12
displays the next help topic in the history sequence
Menu: View -> Home or Command: HH[OME]
displays the first help topic in the history sequence and clears the history list.

To scroll up and down within the help current help topic, the following controls are available:

Command: FORWARD or PFKey: 20
scrolls the topic forward by one page
Command: BACKWARD or PFKey: 19
scrolls the topic backward by one page
Command: RIGHT or PFKey: 23
scrolls the topic right by one page width
Command: LEFT or PFKey: 22
scrolls the topic left by one page width
Command: TOP
scrolls the topic to the top
Command: BOTTOM
scrolls the topic to the bottom
Command: FIND <'character-string' <search-order><component>>
Arguments
no argument
Searches for the character string most recently specified in a FIND command.
'character-string'
represents the character string that you want to find.
Search-Order arguments
NEXT
finds the next occurrence of the character string based on the current cursor position.
FIRST
finds the first occurrence of the character string regardless of the cursor position.
LAST
finds the last occurrence of the character string regardless of the cursor position.
PREV
finds the previous occurrence of the character string based on the current cursor position.
ALL
finds all occurrences of the character string and reports the number as a note.
component arguments
WORD
finds a character string within starting and ending delimiters.
PREFIX
finds a character string that is the prefix of a word within the constraints that are established for the WORD argument.
SUFFIX
finds a character string that is the suffix of a word within the constraints that are established for the WORD argument.
ICASE
makes a search case-insensitive.
Command: RFIND or PFKey: 5
repeats the previous FIND command.

Documentation: Accessing Host Help

To access CMS specific help directly, enter help host on the command line, then select host, or, using PMENUs, select Help->SAS System Help->Using SAS with your operating environment.

Documentation: Developing User-Defined Help

You can develop Help for your site or for your SAS programs that can be displayed in the standard SAS Help browser. To ensure that user-defined Help will be displayed as it is written, use only the subset of tags from HTML Version 3.2 that is supported on the SAS Help browser. Help information in tags that not supported by the SAS Help browser may be ignored.

The following HTML tags are supported by the SAS Help browser: H1, H2, H3, H4, H5, H6, P, UL, OL, DIR, MENU, DL, DT, DD, PRE, XMP, LISTING, I, B, U, EM, STRONG, DFN, CODE, SAMP, KBD, VAR, CITE, A, LINK, TITLE, BASE, HEAD, and HTML.

The TABLE tag is the only frequently used tag that is not supported at this time. To add tables to your Help, use the PRE tag and format the text manually by using blank spaces, vertical bars, dashes, and underscores as needed. For more details about developing and using user-defined Help, see Initializing and Configuring the SAS System in the SAS Companion for the CMS Environment, Version 8.

Documentation: Online Documentation (CD-ROM)

The CD-ROM that is supplied with SAS software contains most of the documentation for base SAS, including SAS Language Reference: Dictionary and other titles. If you encounter a problem that you cannot solve with the information that is provided in the SAS log or in SAS online Help, load the CD-ROM disk into a CD-ROM reader and browse through the contents of the books.

Documentation: Hardcopy Documentation

Contact your SAS Support Consultant for assistance with ordering hardcopy documentation.