Previous Topic: 3.3.2.1.1 File DefinitionNext Topic: 3.3.2.1.3 Specification Processing


3.3.2.1.2 Element Selection
 
Figure 3-10, Resource Element File menu, shows the next step
in creating a user-defined resource element file definition.
/---------------------------  Resource Element File  ---------------------------\
|Option ===>                                                                    |
|                                                                               |
|Composing CAP DB file def.:  SYS - System Activity Tracking File               |
|                                                                               |
|                                                                               |
|        1 - Insert Common Data Selection                                       |
|            Specify data selection criteria to apply to ALL files.             |
|        2 - Insert CA MICS File and Data Element Selection                     |
|            Select a CA MICS file and data elements.                           |
|        3 - Insert Cross-File Data Element Definition                          |
|            Specify cross-file data element derivations.                       |
|                                                                               |
|                                                                               |
|                                                                               |
|                                                                               |
|                                                                               |
|                                                                               |
|                                                                               |
|                                                                               |
|                                                                               |
|                                                                               |
|                                                                               |
\------------------------------------------------------------------------------/
  
 Figure 3-10.  Resource Element File Menu

After you complete specifying the resource element file
definition control parameters, you are ready to define the
steps to build your Capacity Planning database file.  (Refer
to Figure 3-2 to see how these steps correspond to user
specifications for the selection, summary, and merge phases
of data base creation.)  The Resource Element File menu
provides you with the opportunity to define selection
criteria that you wish to apply to each CA MICS file that you
define as an input data source for your Capacity Planning
database file.

You may choose from the following options on the Resource
Element File menu:
 
Insert       Specify Option 1, Insert Common Data Selection,
Common Data  to specify the data selection criteria that you
Selection:   wish to apply to every CA MICS file that
             provides input data in building your Capacity
             Planning database file.  The Common Data
             Selection screen shown in Figure 3-11 is
             displayed.
 
             You may specify only one common data selection
             step for each database definition inquiry.  You
             must complete this before proceeding with the
             succeeding steps.

Insert Neu-  Specify Option 2, Insert CA MICS File and Data
MICS File &  Element Selection, to define a CA MICS file and
Data Element data element selection step for each CA MICS
Selection:   file that provides input data for your Capacity
             Planning database file. The CA MICS File and
             data Element Selection screen shown in Figure
             3-13 is displayed.  (Both the file-unique
             selection and summary phases shown in Figure
             3-16 occur during this step.)

             Using this screen and its associated exit
             screens, you can define both the CA MICS and the
             non-CA MICS data elements that will comprise
             your Capacity Planning database file, along with
             any file-unique data selection and/or
             summarization logic.

             If you wish to define any non-CA MICS data
             elements that are derived from CA MICS data
             elements from a single CA MICS file, you can
             usually specify the data element derivation SAS
             statements through one of the exit screens
             associated with this screen.  If you are
             defining non-CA MICS data elements that are
             derived from CA MICS data elements from multiple
             CA MICS files, you can specify the data element
             derivation SAS statements in the cross-file data
             element definition step.

Insert       Specify Option 3, Insert Cross-File Data Element
Cross-File   Definition, to define any non-CA MICS data
Data Element elements that you wish to derive from CA MICS
Definition:  data elements from multiple CA MICS files. The
             Cross-File Data Element Definition screen shown
             in Figure 3-21 is displayed.  (This step
             corresponds to the merge phase shown in Figure
             3-2.)  You must also specify the data element
             derivation SAS statements that will be used to
             derive these non-CA MICS data elements.

             Since the specifications associated with this
             step apply to the merging of data from multiple
             CA MICS files, you may specify a cross-file data
             element definition step only if you specify
             multiple CA MICS file and data element selection
             steps.  In this case, the cross-file data
             element definition step is required to create a
             valid file definition inquiry.

Each time you complete the specifications for an individual
step and type END at the Command prompt, then press ENTER or
(usually) the PF3 key.  The Resource Element File Menu shown
in Figure 3-10 is redisplayed to allow you to insert another
step in your file definition inquiry.  Repeat this process
until you define all of the steps necessary to build your
Capacity Planning database file.

The three options are further discussed in the following
sections:
 
 1 - Insert Common Data Selection
 2 - Insert CA MICS File and Data Element Selection
 3 - Insert Cross-File Data Element Definition
3.3.2.1.2.1 Insert Common Data Selection
If you select Option 1, Insert Common Data Selection, on the
Resource Element File menu, the Common Data Selection screen
shown in Figure 3-11 is displayed.
 
/---------------------------  Common Data Selection  ---------------------------\
|Command ===>                                                                   |
|Enter a ? in any data entry field for more information on valid values.        |
|Composing CAP DB File def.:  SYS - System Activity Tracking File               |
|                                                                               |
|                                                                               |
|SYSID   ===> ____ ____ ____ ____ ____ ____ ____ ____ ____ ____                 |
|             ____ ____ ____ ____ ____                                          |
|                                                                               |
|Zone    ===> _ _ _ _ _ _ _ _ _                                      (1 - 9)    |
|                                                                               |
|Hour    ===> __ - __   __ - __   __ - __   __ - __   __ - __        (0 - 23)   |
|                                                                               |
|Dayname ===> _________ _________ _________ _________ _________                 |
|                                                                               |
|                                                                               |
|                                                                               |
|                                                                               |
|Specify common data selection SAS statements ===> N (Y/N/R)                    |
\------------------------------------------------------------------------------/
 
 Figure 3-11.  Common Data Selection Screen

The data selection criteria that you specify using this
screen is applied to each CA MICS file that provides input
data in creating and updating your Capacity Planning database
file.
 
The parameters for the Common Data Selection screen are
defined below:
 
SYSID:       The SYSIDs that you wish to include in your
             Capacity Planning database file.   You may
             specify a maximum of 15 one- to four-character
             SYSIDs.  Leave this parameter blank to include
             data for all SYSIDs.  The standard method is to
             create one record for each SYSID that is created
             for each day, week, or month processed.

             Alternatively, you may wish to summarize
             multiple SYSIDs into a single record.  You can
             do this by using the Composite SYSID parameter
             on the Resource Element File Definition screen
             shown in Figure 3-7.

Zone:        The zones that you wish to include in your
             Capacity Planning database file.  You may
             specify a maximum of nine one-character zones.
             Leave this parameter blank to include data for
             all zones.  The standard method is to create one
             record for each zone that is created for each
             week or month processed.  Alternatively, you may
             wish to summarize multiple zones into a single
             record.  You can do this by using the Composite
             zone parameters on the Resource Element File
             Definition screen shown in Figure 3-7.

Hour:        The hours that you wish to include in your
             Capacity Planning database file.  You may
             specify a maximum of five hours or hour ranges.
             Leave this parameter blank to include data for
             all hours.

Dayname:     The specification of up to five daynames to be
             included in the Capacity Planner database file.
             Leave blank to include all days.  Input the
             first unique characters and the CA MICS Capacity
             Planner will fill in the rest. Specification of
             this parameter is only valid when the input
             timespan is DETAIL or DAYS.

Specify      Put a Y in this field to specify your own SAS
common data  statements to subset the CA MICS input files.
selection    The SAS Statements screen shown in Figure 3-12
SAS          displays.  Specify R (Reset) to reset any SAS
statements:  statements you previously made.
/---------------------------  SAS System Statements  --------------------------\
|Command ===>                                                  Scroll ===> CSR |
|                                                                              |
|Inquiry Step:  Common Data Selection                                          |
|                                                                              |
|SAS Statements for the SELECT   Macro                                         |
|------------------------------------------------------------------------------|
|****** ***************************** TOP OF DATA *****************************|
|==MSG> SPECIFY SAS STATEMENTS TO SUBSET THE CAPACITY PLANNING DATA BASE FILE. |
|=NOTE= %MACRO SELECT; <=== PLEASE DO NOT PLACE LINES BEFORE THIS LINE.        |
|000001                                                                        |
|000002                                                                        |
|000003                                                                        |
|000004                                                                        |
|000005                                                                        |
|000006                                                                        |
|000007                                                                        |
|000008                                                                        |
|000009                                                                        |
|000010                                                                        |
|=NOTE= %MEND SELECT; <=== PLEASE DO NOT PLACE LINES AFTER THIS LINE.          |
|****** **************************** BOTTOM OF DATA ***************************|
|                                                                              |
\------------------------------------------------------------------------------/
  
 Figure 3-12.  SAS Statements Screen - Selecting Common Data

Using the SAS Statements screen shown above, you can specify
your own data selection logic to apply to each CA MICS file
that provides input data to your Capacity Planning database
file.

Note that the %MACRO SELECT and %MEND SELECT statements are
provided for you and that they are field-protected from
modification.
3.3.2.1.2.2 Insert CA MICS File and Data Element Selection
 
If you select Option 2, Insert CA MICS File and Data Element
Selection, on the Resource Element File menu, the CA MICS
File and Data Element Selection screen shown in Figure 3-13
is displayed.
 
/--------------------  CA MICS File and Data Element Selection  ---------------\
|Command ===>                                                  Scroll ===> CSR |
|Enter a ? in any data entry field for more information on valid values.       |
|Modifying CAP DB File def.:  R03 - sample resource element file               |
|CA MICS file       ===> CPU    (fff) -  CPU ACTIVITY FILE                     |
|Input Time-Span    ===> MONTHS (DETAIL/DAYS/WEEKS/MONTHS)                     |
|Data base (s)      ===> A                                                     |
|Include CAPAPUs    ===> N (Y/N)                   -------Line Commands--------|
|Summarize file by  ===> ________                  | I Insert C Copy D Delete ||
|Specify file exits ===> N (Y/N)                   | R Repeat E Calculations  ||
|                                                  | S Depend Clauses & Label ||
|                                                  ----------------------------|
|                                            Sum  Data                         |
|Cmd  Name   Label (long name)             D Type Type Order Len Output-Format |
| - -------- ----------------------------- - ---- ---- ----- --- ------------- |
| _  DATE     Interval End Date                                                |
|                                            RET  D    000   7   DATE9.        |
| _  MONTH    Month of Year                                                    |
|                                            RET  N    000   2   _____________ |
| _  SYSID    System Identifier                                                |
|                                            RET  A    000   4   _____________ |
| _  TEST     test                                                             |
|                                            COMP N    000   5   _____________ |
| _  YEAR     Year of Century                                                  |
|                                            RET  N    000   2   _____________ |
| _  ZONE     Time Zone                                                        |
|                                            RET  A    000   1   _____________ |
|******************************* BOTTOM OF DATA *******************************|
|                                                                              |
\------------------------------------------------------------------------------/
  
 Figure 3-13.  CA MICS File and Data Element Selection Screen

The parameters for the CA MICS File and Data Element
Selection screen are defined below:
 
CA MICS      The CA MICS file that contains the data elements
file         that you wish to include in your resource
             element file or that you wish to use in deriving
             non-CA MICS data elements. If you are uncertain
             of the file name, type a question mark (?) in
             this field to obtain a complete selection list
             for your installation.

Input File   The timespan (DETAIL, DAYS, WEEKS, or MONTHS)
Time-Span    of the file you are using as input.

Data base:   The database unit identifier(s) (up to fourteen
             units) that contain the specified CA MICS file.
             If you are uncertain of which database unit the
             CA MICS file resides in, type a question mark
             (?)  in this field to obtain a complete
             selection list for your installation.

Include      The specification for whether the Application
CAPAPUs:     unit (CAPAPU) data elements are to be included
             in the summarization sequence for this file.
             This parameter defaults to Y (YES) if CAPAPUs
             are defined for this resource element file.  The
             CAPAPU derivation exit is invoked for each input
             file observation.  If you do not want to include
             CAPAPUs in the summarization sequence, type an N
             (NO) in this field.

Summarize    The specification that allows you to add a data
file by:     element to the intermediate file summarization
             sequence of this resource element file.  This
             may be either a CA MICS or a non-CA MICS data
             element.  Any data element that you specify as a
             summarization data element is dropped from the
             database file following the summarization phase.
             If you want to include a data element in the
             summarization sequence and retain it on the
             file, use the CAPAPU feature to hold the values
             of the data element.

Specify      The specification for CA MICS file processing
file exits:  exits.  You must specify a Y (YES) if you intend
             to code CA MICS file-unique data selection,
             summary, or data derivation logic.  If you
             specify a Y, the CA MICS File Processing Exits
             Menu shown in Figure 3-16 is displayed.

The display portion of this screen contains a scrollable list
of the CA MICS and non-CA MICS data elements that you can
either include in your capacity planning database file or use
to derive other data elements.  It contains the following
fields:
 
Cmd:         The line commands are:
 
               I (insert) to insert a new data element.
               R (repeat) to repeat a data element.
               S (depend clauses and label) to specify
                 independent data elements upon which this
                 data element depends. See Figure 3-14.
               C (copy) to copy a data element.
               E (expression) to create SAS code to calculate
                 the value of this specific data element. See
                 Figure 3-15.
               D (delete) to delete a data element.

Name:        The name of the data element.  This may be
             either the name of a CA MICS data element that
             exists in the input CA MICS file or any valid
             SAS name, as described in the SAS manuals.  If
             you wish to define non-CA MICS data elements,
             choose variable names that are descriptive of
             the values they represent.

             Note that when you first see this screen, it
             displays only the control data elements that are
             always present in your capacity planning
             database file.  If you attempt to modify these
             data elements, an error will occur.  Define an
             additional row for each data element that you
             wish to include in your capacity planning
             database file by typing an I (INSERT) in the Cmd
             column of any existing row.

             If you are uncertain of the correct spelling of
             a CA MICS data element or if you would like to
             see a complete list of the CA MICS data elements
             available in the CA MICS input file, type a
             question mark (?) in the name field to display
             the screen shown in Figure 3-20.

Data Element The data element label that is displayed on the
Label        CAP File and Data Element Selection screen and
(long name): on many reports.  This label is supplied
             automatically for input data elements.

D:           The data element drop flag.  Typing a D in this
             field makes the corresponding data element
             available for use in calculations through the
             cross-file data element definition step of the
             capacity planning database file update, but
             drops the data element from the resulting
             capacity planning database file.  Leave the
             field blank to keep the corresponding data
             element on the capacity planning database file.

Sum Type:    The summarization type of the data element:  RET
             (retain), ACCM (accumulate), MIN (minimum), MAX
             (maximum), and COMP (compute).

Data type:   The type of data element.  This is used to
             validate data values and usage for the data
             element.  Valid types are Alphanumeric (A),
             Numeric (N), Money (M), Time (T), Hex (H), Date
             (D), Time-of-day (TD), and Date-Time (DT).  This
             value is supplied automatically for CA MICS data
             elements.

Order:       Define the execution order of the data elements
             you defined by entering ordinal numeric values
             greater than 100.
             Note:  This is required if you are going to use
             this Resource Element file as input to a Meta
             file.

             The order value is automatically defined for
             CA MICS data elements and Capacity Planner
             Control elements.  Data elements that require
             other data elements are automatically included
             in the Capacity Planner database file.  In
             particular, two variables could appear that will
             not show up in the output file:  @@FIRST and
             @@LAST.

Len:         The length of the data element.  This value is
             supplied automatically for CA MICS data
             elements.

Output       The SAS format that is used to print data
Format:      element values.  This value is supplied
             automatically for CA MICS data elements.
 
/-----------------------  Resource Element File Definition  -------------------\
|Command ===>                                                                  |
|                                                                              |
|Data Element                                                                  |
|       Name:      MYVAR    From File: CPU  CPU ACTIVITY FILE                  |
|       Label ===> MY VARIABLE                                                 |
|       Type  ===> COMPUTE                                                     |
|                                                                              |
|------------  -------- -------- -------- -------- -------- -------- --------  |
|DEPEND 01===> CPUPCBSY ________ ________ ________ ________ ________ ________  |
|DEPEND 02===> ________ ________ ________ ________ ________ ________ ________  |
|DEPEND 03===> ________ ________ ________ ________ ________ ________ ________  |
|DEPEND 04===> ________ ________ ________ ________ ________ ________ ________  |
|DEPEND 05===> ________ ________ ________ ________ ________ ________ ________  |
|DEPEND 06===> ________ ________ ________ ________ ________ ________ ________  |
|DEPEND 07===> ________ ________ ________ ________ ________ ________ ________  |
|DEPEND 08===> ________ ________ ________ ________ ________ ________ ________  |
|DEPEND 09===> ________ ________ ________ ________ ________ ________ ________  |
|DEPEND 10===> ________ ________ ________ ________ ________ ________ ________  |
|                                                                              |
|                                                                              |
|                                                                              |
\------------------------------------------------------------------------------/
  
 Figure 3-14.  Defining Resource Element File Dependencies and Labels

The Depend Clause and Label screen is used to define those
variables in the input file that are required by the SAS
statements (either in the CAPSMRY or in Expression
Statements) to calculate the value of the data element being
selected. For example, if you had a data element MYVAR that
required the presence of CPUPCBSY to calculate its value, you
would place CPUPCBSY on this screen, as shown in Figure 3-14.
Once specified, the CA MICS Capacity Planner will carry
forward these independent elements as required to recalculate
the value of MYVAR.
 
/----------------------------  Expression Statements   ------------------------\
|Command ===>                                                                  |
|                                                                              |
|Expression statements for variable: MYVAR                                     |
|----------------------------------------------------------------------------- |
|*********************************** TOP OF DATA ***************************** |
|=NOTE= SET THE EXPRESSION STATEMENTS FOR THIS DATA ELEMENT.                   |
|000001 IF CPUPCBSY LT 70.0                                                    |
|000002 THEN MYVAR = 'OK';                                                     |
|000003 ELSE IF CPUPCBSY GT 70.0                                               |
|000004      THEN MYVAR = 'WARN';                                              |
|000005      ELSE IF CPUPCBSY GT 85.0                                          |
|000006           THEN MYVAR = 'INVESTIGATE';                                  |
|000007           ELSE IF CPUPCBSY GT 95.0                                     |
|000008                THEN MYVAR = 'CONSTRAINED';                             |
|000009                                                                        |
|000010                                                                        |
|000011                                                                        |
|******************************* BOTTOM OF DATA ****************************** |
\------------------------------------------------------------------------------/
 
 Figure 3-15.  Setting Expression Statements

You use this screen (Figure 3-15) to set the Expression
Statements for a particular variable name (in this case
MYVAR). The CA MICS Capacity Planner will then use these SAS
Statements to calculate the value for MYVAR.  If you have
already coded statements in a MACRO (either CAPSMRY or
CAPMERG) you can use the Converting Macros to Expression
Statements to perform this association.
 
/---------------------  CA MICS File Processing Exits Menu  -------------------\
|Command ===>                                                                  |
|                                                                              |
|Inquiry Step:  File & Data Element Sel.: JOB - Batch User Job Activity File   |
|                                                                              |
|Specify file unique data selection SAS stmts.   ===> N (Y/N/R)                |
|   (file level SELECT exit)                                                   |
|                                                                              |
|Specify new data element derivation SAS stmts.  ===> N (Y/N/R)                |
|   (file transpose and summary exit)                                          |
|                                                                              |
|Set expression statements for data elements.    ===> N (Y/N)                  |
|   (convert SAS stmts to Expression stmts.)                                   |
|                                                                              |
|                                                                              |
|                                                                              |
|                                                                              |
|                                                                              |
|                                                                              |
|                                                                              |
|                                                                              |
|                                                                              |
\------------------------------------------------------------------------------/
  
 Figure 3-16.  CA MICS File Processing Exits Menu

Figure 3-16 shows the CA MICS File Processing Exits Menu that
is displayed if you specify a Y (YES) for the Specify CA MICS
file processing exits parameter on the CA MICS File and Data
Element Selection screen shown in Figure 3-13.
 
The following options are available:
 
Specify      The specification for assigning SAS statements
file unique  to select file-unique data.  Specify a Y (YES)
data         if you wish to supply the SAS statements
selection    necessary to implement a special observation
SAS stmts:   selection method.

Specify      The specification for assigning SAS statements
new data     to derive new data elements.  Specify a Y (YES)
element      if you wish to supply the SAS statements
derivation   necessary to define new data elements that are
SAS stmts:   not part of the standard CA MICS file. Use this
             exit to initialize your data elements, also.  If
             you are creating a new computed data element,
             you set the initial value of the data element
             here. Specify expression statements that would
             be used to recalculate the value of the data
             element if used in a meta file.

Set
expression
statements   Set to Y (YES) to convert existing Resource
for data     Element File SAS statements (CAP Summary) to
elements:    expression statements or calculations.

Figures 3-17 and 3-18 show how you can use the SAS Statements
screen to enter these SAS statements.
 
/---------------------------  SAS System Statements  --------------------------\
|Command ===>                                                  Scroll ===> CSR |
|                                                                              |
|Inquiry Step:   File & Data Element Sel.: JOB - Batch User Job Activity File  |
|                                                                              |
|SAS Statements for the CAPSLCT  Macro                                         |
|------------------------------------------------------------------------------|
|****** ***************************** TOP OF DATA *****************************|
|==MSG> SPECIFY SAS STATEMENTS TO SUBSET THIS PARTICULAR FILE.                 |
|=NOTE= %MACRO CAPSLCT; <=== PLEASE DO NOT PLACE LINES BEFORE THIS LINE.       |
|000001                                                                        |
|000002                                                                        |
|000003                                                                        |
|000004                                                                        |
|000005                                                                        |
|000006                                                                        |
|000007                                                                        |
|000008                                                                        |
|000009                                                                        |
|000010                                                                        |
|=NOTE= %MEND CAPSLCT; <=== PLEASE DO NOT PLACE LINES AFTER THIS LINE.         |
|****** **************************** BOTTOM OF DATA ***************************|
|                                                                              |
\------------------------------------------------------------------------------/
 
 Figure 3-17.  SAS Statements Screen - Selecting File Unique Data

Use the SAS Statements screen shown in Figure 3-17 to code
valid SAS statements that conform to the syntax described in
the SAS manuals to define CA MICS file-unique data selection
logic.
 
/---------------------------  SAS System Statements  --------------------------\
|Command ===>                                                  Scroll ===> CSR |
|                                                                              |
|Inquiry Step:   File & Data Element Sel.: JOB - Batch User Job Activity File  |
|                                                                              |
|SAS Statements for the CAPSMRY  Macro                                         |
|------------------------------------------------------------------------------|
|****** ***************************** TOP OF DATA *****************************|
|==MSG> SPECIFY SAS STATEMENTS FOR TRANSPOSING THE FILE OR TO SET VARIABLES.   |
|=NOTE= %MACRO CAPSMRY; <=== PLEASE DO NOT PLACE LINES BEFORE THIS LINE.       |
|000001                                                                        |
|000002                                                                        |
|000003                                                                        |
|000004                                                                        |
|000005                                                                        |
|000006                                                                        |
|000007                                                                        |
|000008                                                                        |
|000009                                                                        |
|000010                                                                        |
|=NOTE= %MEND CAPSMRY; <=== PLEASE DO NOT PLACE LINES AFTER THIS LINE.         |
|****** **************************** BOTTOM OF DATA ***************************|
|                                                                              |
\------------------------------------------------------------------------------/
 
 Figure 3-18.  SAS Statements Screen - Deriving New Data Elements

Use the SAS Statements screen shown in Figure 3-18 to code
valid SAS statements that conform to the syntax described in
the SAS manuals to derive non-CA MICS data elements or
summarization logic.

The CAPSMRY macro is used for several different purposes by
the CA MICS Capacity Planner and it is very important to
understand how this relates to the overall creation of a
Capacity Planner file and, particularly, the creation of your
own data elements.

You can specify user-created data elements and the type of
data element you are creating.  The data element types
available are: Maximum, Minimum, Accumulated, Retained, and
Computed. This type designation defaults to Retained for your
data elements unless you override the setting, which may be
any of these values.  The data element type is used by the
CA MICS Capacity Planner to determine how to process a
particular user data element. To determine how to use the
CAPSMRY for a particular data element please review the
following criteria and take the appropriate action
accordingly.

If you wish to use the Meta File Facility:
 
    For data elements that have a data element type of
    computed you do not need to use the CAPSMRY exit. You
    should use Expression Statements to contain the SAS code
    needed to calculate the value of the data element. If you
    currently have files that were created with a release of
    the CA MICS Capacity Planner prior to CAP6100 and wish to
    convert a data element from the default of RETained to
    COMputed, there is an option on the extended options menu
    provided for this migration.  Make sure that you change
    the Data Element Type for these variables (from RETained)
    because Expression Statements are only valid for COMputed
    variables.

    For data elements that are not COMputed, you would
    specify the necessary SAS statements in the CAPSMRY Macro
    to set the initial value of the variable.  If you are
    transposing the file, you should specify the SAS
    statements to perform this transformation here in the
    CAPSMRY. The data element type takes affect for
    non-computed variables only in the Meta File Facility.

If you do not wish to use the Meta File Facility:
 
    If you do not wish to use the Meta File Facility, the
    data data element type is less important (the default of
    RETained is sufficient) and all variables should be set
    via the CAPSMRY exit. This is true whether or not you are
    transposing the file.

The following Data Element Type table describes the
relationship between the CAPSMRY macro and expression
statements.
 
Data         Used in
Element      Meta      Need SAS Code    Need Expression
Type         File?     in CAPSMRY?      Statements?
 
Maximum      No        Yes, to set      No
                       the value
 
Maximum      Yes       Yes, to set      No, handled in Meta
                       initial value    Files automatically
 
Minimum      No        Yes, to set      No
                       the value
 
Minimum      Yes       Yes, to set      No, handled in Meta
                       initial value    files automatically
 
Accumulated  No        Yes, to set      No
                       the value
 
Accumulated  Yes       Yes, to set      No, handled in Meta
                       initial value    files automatically
 
Retained     No        Yes, to set      No
                       the value
 
Retained     Yes       Yes, to set      No, handled in Meta
                       initial value    files automatically
 
Computed     No        Yes, to set      No
                       the value
 
Computed     Yes       No               Yes, Expression
                                        statements used by
                                        both Resource Element
                                        File creation and in
                                        Meta files
 
/----------------  Converting Macros to Expression Statements  ----------------\
|Command ===>                                                 Scroll ===> CSR  |
|                                                                              |
|Enter the variable names that are associated with the SAS statements shown    |
|below.                                                                        |
|                                                                              |
|Variable  SAS Statements in Macro                                             |
|-------- ------------------------------------------------------------------   |
|MYVAR2__ IF CPUAVB GT 10  /* IF THE AVERAGE NUMBER OF BATCH JOBS */           |
|MYVAR2__ THEN MYVAR2 = 'CHECK'; /* IS GREATER THAN 10 WE SHOULD  */           |
|MYVAR2__ ELSE MYVAR2 = 'OK'; /* CHECK IT OUT */                               |
|****************************** BOTTOM OF DATA ********************************|
\------------------------------------------------------------------------------/
  
 Figure 3-19. Converting Macros to Expression Statements

You use this screen (see Figure 3-19) to convert existing
MACRO statements into Expression Statements that calculate
the value of a particular variable. In the example shown in
Figure 3-19, the variable MYVAR2 is a user-created data
element that is used to warn the user of this file whenever
CPUAVB is larger than 10. This variable was originally
created using the CAPSMRY MACRO.  By placing "MYVAR2" in the
Variable Column of this screen, the CA MICS Capacity Planner
will automatically associate these SAS Statements with
MYVAR2.  When you End from this display, the CA MICS Capacity
Planner will remove the statements from the MACRO and move
them into the Expression Statement table for the variable
MYVAR2.
 
/---------------------------  Data Element Selection  --------------------------\
|Command ===>                                                  Scroll ===> CSR  |
|                                                                               |
|Inquiry Step:  Common Data Selection                                           |
|Input File:    MONTHS JOB - BATCH USER JOB ACTIVITY FILE                       |
|                                                                               |
|Line Cmds: S Select  H Data Dictionary Display                                 |
|                                                                               |
|               Select Data Elements                                            |
|Cmd  Element        Data Element Label (long name)                             |
| -   --------  ----------------------------------------                        |
| _   ACCTNO1   DIVISION                                                        |
| _   ACCTNO2   PROJECT                                                         |
| _   ACCTNO3   USER                                                            |
| _   ENDTS     End Time Stamp                                                  |
| _   JOBACOMM  Communication Data Set Allocations                              |
| _   JOBACTTM  Job Active Time                                                 |
| _   JOBADASD  DASD Data Set Allocations                                       |
| _   JOBAGRAF  Graphics Data Set Allocations                                   |
| _   JOBALCTM  Job Allocation Time                                             |
| _   JOBAMSS   MSS Data Set Allocations                                        |
| _   JOBATAPE  Tape Data Set Allocations                                       |
| _   JOBAUREC  Unit Record Data Set Allocations                                |
| _   JOBAVIO   VIO Data Set Allocations                                        |
|                                                                               |
\------------------------------------------------------------------------------/
  
 Figure 3-20. Data Element Selection Screen

If you enter a question mark (?) in the "name" field of the
CA MICS File and Data Element Selection screen shown in
Figure 3-13, the Data Element Selection screen (Figure 3-20),
which is the final screen in this series, is displayed.

This screen presents a full list of data elements within the
CA MICS file that you specified. You may select data elements
to include in the resource element file by placing an S
(SELECT) in the Cmd column that corresponds to the data
element you want to include in your capacity planning
database file.
3.3.2.1.2.3 Insert Cross-File Data Element Definition
 
If you specify data selection from more than one CA MICS file
through Option 2 on the Resource Element File menu shown in
Figure 3-10, you must also insert a cross-file data element
definition step in your file definition.  Select Option 3,
Cross-File Data Element Definition, to define data elements
that are calculated from CA MICS or user-defined data
elements from more than one file.  This screen displays all
the data elements, including the control data elements, that
you selected from all CA MICS files.
 
/---------------------  Cross-File Data Element Definition  -------------------\
|Command ===>                                                  Scroll ===> CSR |
|Enter a ? in any data entry field for more information on valid values.       |
|Modifying CAP DB File def.:  R03 - sample resource element file               |
|                                                                              |
|Specify:                                          -------Line Commands--------|
| SAS exit stmts.   ===> N (Y/N/R)                 | I Insert C Copy D Delete ||
|                                                  | R Repeat E Calculations  ||
| Expression stmts. ===> N (Y/N/R)                 | S Depend Clauses & Label ||
|                                                  ----------------------------|
|                                             Sum  Data                        |
|Cmd  Name    Label (long name)             D Type Type Order Len Output Format|
| -  -------- ----------------------------- - ---- ---- ----- --- -------------|
| _  MONTH    Month of Year                                                    |
|                                             RET  N    000   2   _____________|
| _  YEAR     Year of Century                                                  |
|                                             RET  N    000   2   _____________|
| _  SYSID    System Identifier                                                |
|                                             RET  A    000   4   _____________|
| _  CPUPCBSY Pct Processor Bus                                                |
|                                             COMP N    050   5   MAPCT.       |
| _  DATE     Interval End Date                                                |
|                                             RET  D    000   7   DATE9.       |
| ******************************* BOTTOM OF DATA ******************************|
|                                                                              |
\------------------------------------------------------------------------------/
 
 Figure 3-21.  Cross-File Data Element Definition Screen

The parameters for the Cross-File Data Element Definition
screen are defined below:
 
Specify      The specification for assigning SAS statements
SAS exit     to derive cross-file elements.  Specify a Y
stmts:       (YES) if you wish to define cross-file data
             elements. (See Figure 3-22.)

Specify      The specification for defining Expression
Expression   statements.  Specify a Y (YES) if you wish to
stmts:       define expression statements.

Cmd:         The line commands are:
 
               I (insert) to insert a new data element.
               R (repeat) to repeat a data element.
               S (depend clauses and label) to specify
                 independent data elements upon which this
                 data element depends. See Figure 3-14.
               C (copy) to copy a data element.
               E (expression) to create SAS code to calculate
                 the value of this specific data element. See
                 Figure 3-15.
               D (delete) to delete a data element.

Name:        The name of the data element.  This may be
             either the name of a CA MICS data element that
             exists in the input CA MICS file or any valid
             SAS name, as described in the SAS manuals.  If
             you wish to define non-CA MICS data elements,
             choose variable names that are descriptive of
             the values they represent.
 
             Note that when you first see this screen, it
             displays only the control data elements that are
             always present in your Capacity Planning
             database file.  If you attempt to modify these
             data elements, an error will occur.  Define an
             additional row for each data element that you
             wish to include in your Capacity Planning
             database file by typing an I (INSERT) in the Cmd
             column of any existing row.

             If you are uncertain of the correct spelling of
             a CA MICS data element or if you would like to
             see a complete list of the CA MICS data elements
             available in the CA MICS input file, type a
             question mark (?) in the name field to display
             the screen shown in Figure 3-20.

Data Element The data element label that is displayed on the
Label        CAP File and Data Element Selection screen and
(long name): on many reports.  This label is supplied
             automatically for CA MICS data elements.

D:           The data element drop flag.  Typing a D in this
             field makes the corresponding data element
             available for use in calculations through the
             cross-file data element definition step of the
             Capacity Planning database file update, but
             drops the data element from the resulting
             Capacity Planning database file.  Leave the
             field blank to keep the corresponding data
             element on the Capacity Planning database file.

Sum Type:    The summarization type of the data element.
             Summarization types are RET (retain), ACCM
             (accumulate), MIN (minimum), MAX (maximum),
             and COMP (compute).

Data type:   The type of data element.  This is used to
             validate data values and usage for the data
             element.  Valid types are Alphanumeric (A),
             Numeric (N), Money (M), Time (T), Hex (H), Date
             (D), Time-of-day (TD), and Date-Time (DT).  This
             value is supplied automatically for CA MICS data
             elements.

Order:       Define the execution order of the data elements
             you defined by entering ordinal numeric values
             greater than 300.
 
             Note:  This is required if you are going to use
             this Resource Element file as input to a Meta
             file.

             The order value is automatically defined for
             CA MICS data elements and Capacity Planner
             control elements.  Data elements that require
             other data elements are automatically included
             in the Capacity Planner database file.  In
             particular, two variables could appear that will
             not show up in the output file:  @@FIRST and
             @@LAST.

Len:         The length of the data element.  This value is
             supplied automatically for CA MICS data
             elements.

Output       The SAS format that is used to print data
Format:      element values.  This value is supplied
             automatically for CA MICS data elements.
/---------------------------  SAS System Statements  --------------------------\
|Command ===>                                                  Scroll ===> CSR |
|                                                                              |
|Inquiry Step:   Cross-file data element derivation                            |
|                                                                              |
|SAS Statements for the CAPMERG  Macro                                         |
|------------------------------------------------------------------------------|
|****** ***************************** TOP OF DATA *****************************|
|==MSG> SPECIFY SAS STATEMENTS TO SET VARIABLES IN THE CROSS-FILE MERGE.       |
|=NOTE= %MACRO CAPMERG; <=== PLEASE DO NOT PLACE LINES BEFORE THIS LINE.       |
|000001                                                                        |
|000002                                                                        |
|000003                                                                        |
|000004                                                                        |
|000005                                                                        |
|000006                                                                        |
|000007                                                                        |
|000008                                                                        |
|000009                                                                        |
|000010                                                                        |
|=NOTE= %MEND CAPMERG; <=== PLEASE DO NOT PLACE LINES AFTER THIS LINE.         |
|****** **************************** BOTTOM OF DATA ***************************|
|                                                                              |
\------------------------------------------------------------------------------/
 
 Figure 3-22.  SAS Statements Screen - Deriving Cross-file Data Elements

Using the SAS Statements screen shown in Figure 3-22, you can
code any valid SAS statements that conform to the syntax
described in the SAS manuals to derive non-CA MICS data
elements.

Note that the %MACRO CAPMERG and %MEND CAPMERG statements are
provided for you and that they are field protected from
modification.
 
/----------------  Converting Macros to Expression Statements  ----------------\
|Command ===>                                                 Scroll ===> CSR  |
|                                                                              |
|Enter the variable names that are associated with the SAS statements shown    |
|below.                                                                        |
|                                                                              |
|Variable  SAS Statements in Macro                                             |
|-------- ------------------------------------------------------------------   |
|RATIO___ IF CPUTOBTM GT 0                                                     |
|RATIO___ THEN RATIO = PGACPUTM / CPUTOBTM;                                    |
|RATIO___ ELSE RATIO = .;                                                      |
|________                                                                      |
|****************************** BOTTOM OF DATA ********************************|
\------------------------------------------------------------------------------/
 
 Figure 3-23.  Converting Macros to Expression Statements

You use this screen (see Figure 3-23) to convert existing
MACRO statements into Expression Statements that calculate
the value of a particular variable. In the example shown in
Figure 3-23, the variable RATIO is a user-created data
element that corresponds to the ratio of Performance Group
Activity (PGA) file CPU time consumed and the total Busy time
of the processor. By placing "RATIO" in the Variable Column
of this screen the CA MICS Capacity Planner will
automatically associate these SAS Statements with RATIO. When
you End from this display the CA MICS Capacity Planner will
remove the statements from the MACRO and move them into the
Expression Statement table for the variable RATIO.