Previous Topic: 1.3.1 OS/390 Data Set Naming Conventions

Next Topic: 1.3.3 Archive SAS File Label Conventions

1.3.2 Online SAS File Label Conventions


The SAS File Label plays an integral role in the use and
access of the Database.  As was mentioned in the Example of
Data Structure and Reference section, the online Database
contains "mini-files," each of which is a unique SAS file.
The following discussion presents the conventions and rules
for these file labels.

The SAS label that identifies a unique file within the
Database contains two parts (part1.part2) where part1 names
the Timespan (e.g., DAYS) and part2 the required File Cycle
within that Timespan.  Note that part1 is actually a SAS
macro variable for the DDNAME defining the OS data set to be
used, and in the definition of the Database, the DDNAME is
directly related to the Timespan level.

Therefore, a SAS file label that is used for the SAS SET
statement is defined as shown below:

                                  PART1.PART2
                                &diiit..iiifffll
     Database identifier_________| | |   | |  |
                                   | |   | |  |
 Information Area level definition_| | __| |  |
                                     |     |  |
      Timespan level definition______|     |  |
                                           |  |
              File level definition________|  |
                                              |
         Cycle Level definition_______________|


Database:  Each database in the CA MICS system is assigned
a unique one-character installation-defined identifier.

Information Area:  The level names that may appear for
Information Area include ADM, TSO, HAR, SCP, and BAT, for
Administrative, TSO, Hardware Utilization, MVS SCP, and the
Batch Information Areas respectively.  See the individual
product guides for a full list of Information Areas.

Timespan:  The level names that may appear include X, D,
W, M, Y, and T, for DETAIL, DAYS, WEEKS, MONTHS, YEARS, and
TABLES respectively.

File:  The names that may appear for Files are a function
of each Information Area.

Cycle:  The values that may appear for Cycle level must be
in the two-digit numeric range of 01 to 99, with the upper
value a function of how many Cycle versions (e.g., number of
days, weeks, months, years) were defined for the File at
installation.  The 00 Cycle is supported for the WEEKS,
MONTHS, and YEARS Timespan.

The following reflects several examples of referencing a
specific SAS file in the (primary) Database:

    &PTSOD..TSOTSO01: The daily TSO System Activity File for
       yesterday.

    &PTSOD..TSOTSO02: The  daily TSO System Activity File for
       two days ago.

    &PTSOW..TSOTSO01: The weekly TSO System Activity File for
       last week.

    &PTSOW..TSOTSO04: The weekly TSO System Activity File for
       four weeks ago.

    &PTSOW..TSOTSO00: The week-to-date TSO System Activity
       File for this week.

    &PTSOM..TSOTSO00: The month-to-date TSO System Activity
       File for this month.


THE %MFILE MACRO:

CA MICS also provides a SAS macro you can invoke in your
programs to construct the SAS file label reference.  The
examples that follow use the %MFILE macro in SAS SET
statements, but use of the macro is also allowed with other
statements that require a file reference.


Statement Formats:

    %MFILE(F=fff,TS=ttt,DB=x);
    %MFILE(F=fffcc,TS=ttt,DB=x);
    %MFILE(F=fffcc-cc,TS=ttt,DB=x);

where:

    fff=file name key - e.g., JOB for the BATJOB file
     cc=cycle number - e.g., 01
    ttt=timespan - DETAIL, DAYS, WEEKS, MONTHS, YEARS, APPL
      x=database unit identifier - single letter

    The DB=x is optional.  Will default to the current unit.

 Example 1:

  DATA X; SET &PBATX..BATJOB01;

  can also be coded as:

  DATA X; SET %MFILE(F=JOB,TS=DETAIL,DB=P);


 Example 2:

  DATA X; SET &PBATX..BATJOB02;

  can also be coded as:

  DATA X; SET %MFILE(F=JOB02,TS=DETAIL,DB=P);


 Example 3:

  DATA X;
  SET &PBATX..BATJOB03 &PBATX..BATJOB02 &PBATX..BATJOB01;

  can also be coded as:

  DATA X; SET %MFILE(F=JOB03-01,TS=DETAIL,DB=P);