Chapter Contents

Previous

Next
SAS Companion for the OS/2 Environment

Creating a Scaled-Down Configuration of the SAS System for Distribution

The SAS System under OS/2 provides a file resource tracking facility that allows you to keep track of which files the SAS System uses during a particular SAS session. This information can be valuable for several reasons:

To generate a list of files that the SAS System opens and closes during a particular session:

  1. Specify the RTRACE and RTRACELOC system options when you start the SAS System. You can specify these options in the Parameters field of the SAS System under OS/2-Version 8 Properties page, in the configuration file (SASV8.CFG), or as part of a SAS command that you specify. For more information about specifying options when you start the SAS System, see SAS System Options under OS/2.

    Issue the RTRACE and RTRACELOC system options by using the following syntax

    -rtrace all -rtraceloc c:\sas\filename.ext
    where filename.ext is the name of the file to which the SAS System writes the list of opened files.

  2. During the SAS session, perform the actions that a user who will be working with the subset of SAS files will perform. For example, if a user will use a particular SAS/AF application, run that application during this session.
    CAUTION:
    If you do not include all of the necessary files in your scaled-down configuration of the SAS System, you might get unexpected results from your SAS application. To ensure that all of the necessary file resources are recorded, you must traverse every path in your SAS session that an end user of the scaled-down configuration should be able to traverse. (If you are running a SAS/AF application, you should exercise every possible path, including error conditions.) Otherwise, you might fail to include a necessary file in your run-time configuration of the SAS System. If you do not include all of the necessary files in your scaled-down configuration of the SAS System, you might get unexpected results from your SAS application.  [cautionend]

  3. When you are finished with the SAS session, exit the SAS System. Be sure to remove the RTRACE and RTRACELOC option specifications from wherever you put them (for example, the SAS program item or SASV8.CFG file).

This procedure results in a list of the files (located in filename.ext) that the SAS System opened and closed during your SAS session.

You can use the COPYSAS autocall macro to create a batch program to copy this subset of files. This automates and simplifies the task of distribution.

To use the COPYSAS macro to create a copy script for a scaled-down configuration of the SAS System, submit a statement with the following syntax:

%COPYSAS (copydir,rtracelog cpcmd scriptloc mkcmd

where

copydir
is the destination SAS root directory for the scaled-down configuration. You can specify copydir as a local directory (for example, c:\mysas) or as a network path (for example, \\server\share\pubsas).

rtracelog
is the log file that is created when you use the RTRACE and RTRACELOC system options.

cpcmd
is the DOS copy command, with options, that you want to use in the copy script. The default is COPY /V.

scriptloc
is the location of the resulting batch file containing the copy commands. The default is COPYSAS.BAT in your SASUSER folder.

mkcmd
is the DOS make directory command, with options, that you want to use in the copy script. The default is MKDIR.

For complete information about the COPYSAS macro, see COPYSAS Autocall Macro.


Chapter Contents

Previous

Next

Top of Page

Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.