Previous Topic: 6.2.2.2 Add File in a Timespan

Next Topic: 6.2.2.4 Change a File's Compression Eligibility

6.2.2.3 Change a File's Sequence in a Timespan


The most complicated level of file tailoring involves
changing data element statements to modify the sequence of
observations within a file.

The statements listed below define an example Network
Performance Analyzer (NPA) component with one file, the
Network Control Program File.  These statements would be
found in the components cccGENIN member in
sharedprefix.MICS.GENLIB.  Data element definition statements
that define the sequence of file observations in any timespan
are indicated by "-->" in the left margin of the example.

   *
   * NPA component generator statements
   *
   GEN GENFILES
   COMP NPA 050 32000 VBS NOACCT NPA Component
   AREA NPA NPA Activity Information Area
   FILE NCP 00 1 Y Y Y Y N N Y Y NCP Activity File
   TYPE R 3 . 3 . 3 .
   NAME NCPNRFBQ  00  0 0 0 0 0 Free Buffer Queue Length
   NAME NCPNRHQL  00  0 0 0 0 0 NCP Channel Hold Queue Length
   NAME NCPNRIQL  00  0 0 0 0 0 NCP Channel Intrmd Queue Len.
   NAME NCPNRSFB  00  0 0 0 0 0 Free Buffer Count At Slowdown
   TYPE A 5 TIME11.2 6 TIME15.2 6 TIME15.2
   NAME NCPTMFCT  00  0 0 0 0 0 Free Cycle Time
   NAME NCPTMTIS  00  0 0 0 0 0 Time In Slowdown
   TYPE M 3 . 3 . 3 .
   NAME NCPMXANP  00  0 0 0 0 0 Max Available NCP Buffers
   NAME NCPMXFBH  00  0 0 0 0 0 Free Buffer High Water Mark
   TYPE N 3 . 3 . 3 .
   NAME NCPMNFBL  00  0 0 0 0 0 Free Buffer Low Water Mark
   NAME NPANRRLS  99  0 0 0 0 0 .
   NAME NPANRSLS  99  0 0 0 0 0 .
   NAME NPATMAOT  99  0 0 0 0 0 .
   NAME NPATSEIS  99  0 0 0 0 0 .
   NAME NPATSFRU  99  0 0 0 0 0 .
   NAME NPATSLOG  99  0 0 0 0 0 .
   NAME RESNAME   99  0 0 0 0 0 .
   NAME MICSVER   99  0 0 0 0 0 .
-->NAME DAY       99  5 5 N N N .
-->NAME HOUR      99  6 6 6 N N .
-->NAME WEEK      99  0 0 4 N N .
-->NAME YEAR      99  3 3 3 3 3 .
-->NAME MONTH     99  4 4 N 4 N .
   NAME INTERVLS  99  0 0 0 0 0 .
   NAME DURATION  99  0 0 0 0 0 .
   NAME STARTTS   99  0 0 0 0 0 .
-->NAME ENDTS     99  7 0 0 0 0 .
-->NAME ZONE      99  0 0 5 5 4 .
   NAME DAYNAME   99  0 0 N N N .
-->NAME SYSID     99  1 1 1 1 1 .
-->NAME NCPNAME   99  2 2 2 2 2 .
   NAME NETNAME   99  0 0 0 0 0 .

Note the timespan indicators.  For data elements that
merely exist on the file in all timespans, the indicators
are of the form:

   NAME NETNAME   99  0 0 0 0 0 .
                      ---------
                      indicators

Data elements that are part of the key to the file in any
timespan have timespan indicators that are numbers other
than zero in one or more timespans.  Consider ZONE:

NAME ZONE 99  0 0 5 5 4 .
              | | | | |
              | | | | +- 4th item in key to YEARS
              | | | +--- 5th item in key to MONTHS
              | | +----- 5th item in key to WEEKS
              | +------- exists, not in key to DAYS
              +--------- exists, not in key to DETAIL

The NAME statements which define sequence data elements
determine how observations are arranged in the timespans
shown.  This table gives the data elements used as keys to
the sort operations that order the file:

    DETAIL   DAYS     WEEKS    MONTHS   YEARS
    -------  -------  -------  -------  -------
    SYSID    SYSID    SYSID    SYSID    SYSID
    NCPNAME  NCPNAME  NCPNAME  NCPNAME  NCPNAME
    YEAR     YEAR     YEAR     YEAR     YEAR
    MONTH    MONTH    WEEK     MONTH    ZONE
    DAY      DAY      ZONE     ZONE
    HOUR     HOUR     HOUR
    ENDTS

Note that this file does not exist in the YEARS timespan,
according to the FILE statement.  If it did, the order
would be as shown, due to coding in the sequence numbers in
the timespan indicators of the NAME statements for the key
data elements.

Suppose the desired order included another data element.
In this example, let us add NETNAME to the order.  We will
add NETNAME immediately after NCPNAME in all timespans, to
yield:

    DETAIL   DAYS     WEEKS    MONTHS   YEARS
    -------  -------  -------  -------  -------
    SYSID    SYSID    SYSID    SYSID    SYSID
    NCPNAME  NCPNAME  NCPNAME  NCPNAME  NCPNAME
    NETNAME  NETNAME  NETNAME  NETNAME  NETNAME
    YEAR     YEAR     YEAR     YEAR     YEAR
    MONTH    MONTH    WEEK     MONTH    ZONE
    DAY      DAY      ZONE     ZONE
    HOUR     HOUR     HOUR
    ENDTS

Such an order can be constructed by coding the timespan
indicators as:

   NAME RESNAME   99  0 0 0 0 0 .
   NAME MICSVER   99  0 0 0 0 0 .
   NAME DAY       99  6 6 N N N .<--+
   NAME HOUR      99  7 7 7 N N .<--+
   NAME WEEK      99  0 0 5 N N .<--+
   NAME YEAR      99  4 4 4 4 4 .<--+
   NAME MONTH     99  5 5 N 5 N .<--+- data elements modified
   NAME INTERVLS  99  0 0 0 0 0 .   |
   NAME DURATION  99  0 0 0 0 0 .   |
   NAME STARTTS   99  0 0 0 0 0 .   |
   NAME ENDTS     99  8 0 0 0 0 .<--+
   NAME ZONE      99  0 0 6 6 5 .<--+
   NAME DAYNAME   99  0 0 N N N .
   NAME SYSID     99  1 1 1 1 1 .
   NAME NCPNAME   99  2 2 2 2 2 .
+->NAME NETNAME   99  3 3 3 3 3 .
|
+- data element added to sequence

On the surface, this is a very simple change.  It is, for
the new user who has been fortunate enough to make such a
modification before the initial installation of CA MICS.

For users that have installed CA MICS and wish to preserve
the existing data, problems arise.

The first problem is that timespan cycles already closed
have been sequenced in an order different from the new key.
To merge yesterday's data with today's data, for example,
would require special processing.  Such problems occur in the
DETAIL and DAYS timespans of the online CA MICS database,
and with the Audit Archive files associated, if active.

More importantly, existing to-date files in WEEKS,
MONTHS, and YEARS timespans have already been sequenced in
the previous order.  Data following the sequence change
cannot be merged with month-to-date data, for example,
because the keys are unlike.  SAS will terminate the daily
run to update the component that contains such a file if the
to-date files have not been retrofitted with the new key
structure.

This problem is almost identical to the problem of adding or
reconfiguring account codes. See Section 6.3, "Retrofitting
Guidelines," for information on how to retrofit a file to
accommodate a modified file sequence.

****************************
* Making the Modifications *
****************************

To modify the sequence of a file in one or more timespans,
perform the following:

    - Modify the MCG NAME statements for the data elements
      needed to modify the file's sequence.

    - If such a retrofit is needed, follow the instructions
      in Section 6.3, "Retrofitting Guidelines," of this
      document.

    - Run the component generation for the component in
      question.

    - The next daily update for any database unit in which
      the component has been installed will reflect the
      change, and add the data element to the file in the
      desired timespan(s).