1. Database Structure › 1.2 Database Structure and Organization › 1.2.1 Online Data Structure › 1.2.1.6 Example of Data Structure and Reference
1.2.1.6 Example of Data Structure and Reference
It should be apparent by this time that the objective of
the Database structure is to provide an integrated network
of small data files, or "mini-files," which logically
comprise the full Database but individually provide small
files that may be quickly processed. This "mini-file"
approach substantially reduces typical long reporting and
updating run-times. This is accomplished because only a
relatively small amount of data need be processed at any one
time.
This section illustrates the application of the Database
structure. The Database File and Data Element Content are
fully explained in section 1.3, Data Content.
In order to illustrate the capability and flexibility of
this structure consider the requirement to report on the
activity for a TSO user for the month of July 2000. In many
traditional approaches, such a requirement would necessitate
that the necessary monthly files for July 2000 first be
located and then processed through a lengthy run to produce
the desired information. Such an information request
is seldom efficiently and quickly satisfied.
With the CA MICS Database, however, the request would not
only be satisfied with a minimum of resource consumption, but
could even be provided as a response to an online TSO
inquiry!
The hierarchical structure of small data files maintained
in the Database reduces the time to locate and process data
contained in the Database. All information retrieval
requests go through two steps: 1) the physical location of
the pertinent data, and 2) the processing of the located
data. These steps are further explained in the following
discussion.
Location of Data
The first step involves locating the individual SAS
data set to be processed and involves four required database
levels (Timespan, Information Area, File, Cycle). In our
example, consider the following:
o The Timespan to be used is MONTHS (monthly
information),
o The Information Area to be used is TSO,
o The File to be processed is TSO User Activity
(Request was for activity for a specific userid),
o The Cycle to be read should be 06 assuming that the
month in which the request was made is January 2001
(Current month cycle is 00, 12/2000 is 01, 11/2000 is
02, and so on until 07/2000 is 06 at the File level
retained online.
With the above qualifications, the file to be processed
within the Database has been located and is identified by
the SAS file name, &PTSOM..TSOTSU06 (Note, that the file
naming conventions will be fully discussed in section 1.3,
Data Content, and reference to the file name is only used
for purposes of explanation at this time).
It is important to recognize that the location of the
required SAS file (&PTSOM..TSOTSU06) is based on
understanding the database structure and DOES NOT REQUIRE
PROCESSING OF THE DATABASE.
Processing of Located Data
The SAS report writing facilities may be used to select
and report on the service, load, and activity of the
specified userid, using the file identified in the first
stage as input.
The resource requirements for processing the SAS file,
&PTSOM..TSOTSU06, are relatively low due to the small number
of records that must be processed. In this example the
monthly TSO User Activity File is summarized by zone within
userid, and there are a maximum number of three zones and a
maximum number of 500 unique TSO userids. Therefore, the
total number of records contained in this file would be less
than or equal to 1,500 (3 x 500).
This file size is small enough to ensure that the elapsed
processing time to satisfy this information request either as
a batch or online process is in terms of minutes.
Figure 1-8 illustrates the path that is followed through
the Database to the location of the required file to be
processed.
Database
|
+--------+--------+---------+-------+
| | | | |
| | | V |
Level 1: DETAIL DAYS WEEKS MONTHS YEARS
|
---|--
|
V
Level 2: TSO
|
-|-
|
V
Level 3: TSO User Activity
|
-|-
|
+--+--+--+--+--+--+--+--+--+--+--+--+
| | | | | | | | | | | | |
| | | | | | | | | | | | |
Level 4: 01 02 03 04 05 06 07 08 09 10 11 12 13
--
Figure 1-8. Database Level Example
The name used to refer to this file from a SAS program is
&PTSOM..TSOTSU06, where P indicates the PRIMARY database,
TSO the Information Area, M the MONTHS Timespan, TSO User
Activity the File, and the 6th Cycle within the File
containing the desired month.
To illustrate using SAS to access the CA MICS database,
consider the following SAS input examples (the SAS SET
statement is used to access and input data from the
Database):
Data for the month of July:
SET &PTSOM..TSOTSU06;
Data for the last three days:
SET &PTSOD..TSOTSU01 &PTSOD..TSOTSU02 &PTSOD..TSOTSU03;
Data for the last two years:
SET &PTSOY..TSOTSU01 &PTSOY..TSOTSU02;