0% found this document useful (0 votes)
170 views697 pages

CTB - Manual

Manual Control - B

Uploaded by

Oscar Viu
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
170 views697 pages

CTB - Manual

Manual Control - B

Uploaded by

Oscar Viu
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 697

Control-M/Analyzer

9.0.18.100
User Guide

May 2018
Contacting BMC Software
You can access the BMC Software website at http://www.bmc.com. From this website, you can obtain
information about the company, its products, corporate offices, special events, and career opportunities.
United States and Canada

Address BMC SOFTWARE INC Telephone  713 918 8800 Fax 713 918 8000
2103 CITYWEST BLVD  800 841 2031
HOUSTON TX
77042-2827
USA

Outside United States and Canada

Telephone (01) 713 918 8800 Fax (01) 713 918 8000

© Copyright 1999-2018 BMC Software, Inc.


Your use of this information is subject to the terms and conditions of the applicable End User License
Agreement for the product and the proprietary and restricted rights notices included in this
documentation. No part of this publication may be reproduced, stored in a retrieval system, or transmitted
in any form or by any means, electronic, mechanical, photocopying, recording or otherwise, without the
prior written permission of BMC Software, Inc.
BMC, BMC Software, the BMC logo, the BMC Software logo, and other BMC marks, and the tagline “Bring
IT to Life” are the exclusive properties of BMC Software, Inc., or its affiliates or subsidiaries and are
registered or may be registered with the U.S. Patent and Trademark Office and in other countries. All
other BMC trademarks, service marks, and logos may be registered or pending registration in the U.S. or
in other countries. All other trademarks or registered trademarks are the property of their respective
owners.
For BMC Control-M Products that are licensed on the “per CPU – Full Capacity” unit of measurement and
installed in an Amazon Web Services (“AWS”) or Microsoft Azure (“Azure”) cloud environment, a license is
required for the total number of CPUs in each AWS or Azure instance upon which the Product is installed
or which the Product manages, either remotely or locally. For AWS, one CPU is equivalent to one vCPU, as
defined by AWS. For Azure, one CPU is equivalent to up to four Virtual Cores (as defined by Azure),
rounded up to the closest multiple of four.
IBM® Tivoli® Business Service Manager, IBM Tivoli Workload Scheduler, IBM Cognos, IBM InfoSphere
DataStage, IBM iSeries, IBM Websphere, and AIX® are the trademarks or registered trademarks of
International Business Machines Corporation in the United States, other countries, or both.
UNIX® is the registered trademark of The Open Group in the US and other countries.
Linux is the registered trademark of Linus Torvalds.
Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks
of their respective owners.
SAP® R/2 and SAP R/3, SAP Business Objects, and SAP NetWeaver are trademarks or registered
trademarks of SAP AG in Germany and in several other countries.

2
Restricted rights legend
U.S. Government Restricted Rights to Computer Software. UNPUBLISHED -- RIGHTS RESERVED UNDER
THE COPYRIGHT LAWS OF THE UNITED STATES. Use, duplication, or disclosure of any data and
computer software by the U.S. Government is subject to restrictions, as applicable, set forth in FAR
Section 52.227-14, DFARS 252.227-7013, DFARS 252.227-7014, DFARS 252.227-7015, and DFARS
252.227-7025, as amended from time to time. Contractor/Manufacturer is BMC SOFTWARE INC, 2101
CITYWEST BLVD, HOUSTON TX 77042-2827, USA. Any contract notices should be sent to this address.
Customer support
You can obtain technical support by using the BMC Software Customer Support website or by contacting
Customer Support by telephone or e-mail. To expedite your inquiry, see “Before contacting BMC.”
Support website
You can obtain technical support from BMC 24 hours a day, 7 days a week at
http://www.bmc.com/support. From this website, you can:
 Read overviews about support services and programs that BMC offers
 Find the most current information about BMC products
 Search a database for issues similar to yours and possible solutions
 Order or download product documentation
 Download products and maintenance
 Report an issue or ask a question
 Subscribe to receive proactive e-mail alerts when new product notices are released
 Find worldwide BMC support center locations and contact information, including e-mail addresses, fax
numbers, and telephone numbers
Support by telephone or e-mail
In the United States and Canada, if you need technical support and do not have access to the web, call
800 537 1813 or send an e-mail message to [email protected]. (In the subject line, enter
SupID:<yourSupportContractID>, such as SupID:12345). Outside the United States and Canada,
contact your local support center for assistance.
Before contacting BMC
Have the following information available so that Customer Support can begin working on your issue
immediately:
 Product information
• Product name
• Product version (release number)
• License number and password (trial or permanent)
 Operating system and environment information
• Machine type
• Operating system type, version, and service pack or other maintenance level such as PUT or PTF

3
• System hardware configuration
• Serial numbers
• Related software (database, application, and communication) including type, version, and service
pack or maintenance level
 Sequence of events leading to the issue
 Commands and options that you used
 Messages received (and the time and date that you received them)
• Product error messages
• Messages from the operating system, such as file system full
• Messages from related software
License key and password information
If you have questions about your license key or password, contact BMC as follows:
 (USA or Canada) Contact the Order Services Password Team at 800 841 2031, or send an e-mail
message to [email protected].
 (Europe, the Middle East, and Africa) Fax your questions to EMEA Contracts Administration at +31 20
354 8702, or send an e-mail message to [email protected].
 (Asia-Pacific) Contact your BMC sales representative or your local BMC office.
Third party Software
For the provisions described in the BMC License Agreement and Order related to third party products or
technologies included in the BMC Product, see
https://docs.bmc.com/docs/display/workloadautomation/Control-M+Workload+Automation+Documentati
on and click Third-party software (TPS).

4
Contents
About this guide ........................................................................................................... 12
Conventions Used in this Guide ..................................................................................................... 14
Information New to this Version .................................................................................................... 16
Information Relating to Control-M/Restart Users ............................................................................ 16
Related Publications ..................................................................................................................... 17

Introduction ................................................................................................................. 19
INCONTROL Products and IOA ...................................................................................................... 20
Control-M/Analyzer Capabilities ..................................................................................................... 23
Data Types .................................................................................................................................. 24
Automated Actions ....................................................................................................................... 25
Unattended Balancing Operations .................................................................................................. 26
Extended IOA Capabilities ............................................................................................................. 26
Control-M/Analyzer Quality Control ................................................................................................ 26
How Control-M/Analyzer Works ..................................................................................................... 29
Methods of Invoking Control-M/Analyzer ........................................................................................ 30
Input Data Sources ...................................................................................................................... 30
Control-M/Analyzer Runtime Environment ...................................................................................... 31
Balanced Data .............................................................................................................................. 32
Job Flow Under Control-M/Analyzer ............................................................................................... 32
Control-M/Analyzer Implementation............................................................................................... 33
Invoking the Control-M/Analyzer Runtime Environment .................................................................. 41
Control-M/Analyzer Components ................................................................................................... 46
IOA Environment .......................................................................................................................... 52
Prerequisite Condition Concept ...................................................................................................... 52
IOA Calendar Facility .................................................................................................................... 54
Date Definition Concepts............................................................................................................... 55

Online Facilities ............................................................................................................ 58


Overview ..................................................................................................................................... 58
IOA Features................................................................................................................................ 59
Database Variable Definition Facility .............................................................................................. 86
Rule Definition Facility ................................................................................................................ 107
Balancing Mission Definition Facility ............................................................................................. 124
Balancing Status Facility ............................................................................................................. 145

5
Rule Activity Display Facility ........................................................................................................ 157
Condition and Resource Handling Facility ..................................................................................... 180
IOA Log Facility .......................................................................................................................... 195
IOA Calendar Facility .................................................................................................................. 204
Utilities Under ISPF..................................................................................................................... 219

Control-M/Analyzer Variables ....................................................................................... 222


Control-M/Analyzer Variables ...................................................................................................... 223
Database Variables ..................................................................................................................... 225
Automatic Database Variable Creation ......................................................................................... 235
Database Variable Definition Screen ............................................................................................ 236
Defining Database Variables ........................................................................................................ 237
Database Variable Parameters – Summary ................................................................................... 238
NAME Basic Parameters .............................................................................................................. 239
GROUP Basic Parameters ............................................................................................................ 241
CREATED...BY...TYPE: Basic Parameters ...................................................................................... 243
DESC: Basic Parameters ............................................................................................................. 245
MAXIMUM ACTIVE GENERATIONS: Generation Parameters ........................................................... 246
GEN TYPE: Generation Parameters .............................................................................................. 248
CURRENT ACTIVE GENERATIONS: Generations Parameter ........................................................... 249
OLDEST... DATE: Generation Parameters ..................................................................................... 251
LATEST... DATE: Generation Parameters ..................................................................................... 253
TYPE: Validation Parameter ........................................................................................................ 254
MASK: Validation Parameters ...................................................................................................... 255
AutoEdit Variables ...................................................................................................................... 256
Local Variables ........................................................................................................................... 260
System Variables ........................................................................................................................ 261

Expressions and Functions .......................................................................................... 269


Expressions ................................................................................................................................ 271
Functions ................................................................................................................................... 277
ABS: Functions ........................................................................................................................... 282
CALCDATE: Functions ................................................................................................................. 283
CONVDATE: Functions ................................................................................................................ 284
DATASTAMP: Functions .............................................................................................................. 286
DBINFO: Functions ..................................................................................................................... 288
DDINFO: Functions..................................................................................................................... 290
DDNUM: Functions ..................................................................................................................... 292
FILTER: Functions ...................................................................................................................... 294

6
FILTERW: Functions ................................................................................................................... 296
FIND: Functions ......................................................................................................................... 298
FINDCH: Functions ..................................................................................................................... 299
GETJUL: Functions ..................................................................................................................... 300
GETWDAY: Functions ................................................................................................................. 302
HOWMANY: Functions ................................................................................................................ 304
INT: Functions ........................................................................................................................... 306
ISDSN: Functions ....................................................................................................................... 307
ISMEM: Functions....................................................................................................................... 308
ISNUMBER: Functions ................................................................................................................. 310
ISSYSOUT: Functions ................................................................................................................. 312
ISVAR: Functions ....................................................................................................................... 314
LENGTH: Functions .................................................................................................................... 316
LINECOUNT: Functions ............................................................................................................... 317
MAX: Functions .......................................................................................................................... 318
MEMLINES: Functions ................................................................................................................. 320
MIN: Functions ........................................................................................................................... 322
MOD: Functions ......................................................................................................................... 324
NEXTVAR: Functions ................................................................................................................... 326
NOT: Functions .......................................................................................................................... 329
POW: Functions ......................................................................................................................... 330
REPLACE: Functions ................................................................................................................... 331
SQRT: Functions ........................................................................................................................ 333
SUBSTR: Functions ..................................................................................................................... 334
SUM: Functions .......................................................................................................................... 336
TOLER: Functions ....................................................................................................................... 338
TOLOWER: Functions ................................................................................................................. 340
TOUPPER: Functions................................................................................................................... 341
TRIMB: Functions ....................................................................................................................... 342
TRIML: Functions ....................................................................................................................... 343
WORD: Functions ....................................................................................................................... 344
WORDNUM: Functions ................................................................................................................ 346

Rule Definition ........................................................................................................... 348


Rule Definition ........................................................................................................................... 349
EXECUTE Block Structure Overview ............................................................................................. 351
Control-M/Analyzer Variables ...................................................................................................... 351
Rule Parameters – Summaries..................................................................................................... 352
Parameter and Statement Descriptions ........................................................................................ 357
ALWAYS: Data Identification Statement ....................................................................................... 358

7
DESC: Basic Rule Parameter ....................................................................................................... 360
DO Statement: Automated Balancing Statement........................................................................... 361
DO ADDSYM: Automated Balancing Statement ............................................................................. 364
DO BLOCK: Automated Balancing Statement ................................................................................ 368
DO CALLUSER: Automated Balancing Statement .......................................................................... 371
DO COMMIT: Automated Balancing Statement ............................................................................. 373
DO COND: Automated Balancing Statement ................................................................................. 378
DO EXIT: Automated Balancing Statement ................................................................................... 381
DO EXTRACT: Automated Balancing Statement ............................................................................ 382
DO GETMEM: Automated Balancing Statement............................................................................. 397
DO GOTO: Automated Balancing Statement ................................................................................. 399
DO MAIL: Automated Balancing Statement .................................................................................. 402
DO PRINT: Automated Balancing Statement ................................................................................ 405
DO PUTMEM: Automated Balancing Statement ............................................................................. 412
DO REMARK: Automated Balancing Statement ............................................................................. 414
DO RULE: Automated Balancing Statement .................................................................................. 416
DO SET: Automated Balancing Statement .................................................................................... 418
DO SHOUT: Automated Balancing Statement ............................................................................... 421
DO SYSOUT: Automated Balancing Statement.............................................................................. 425
DO TERMINAT: Automated Balancing Statement .......................................................................... 428
EXECUTE: Data Selection Statement ............................................................................................ 430
GROUP: Data Selection Statement ............................................................................................... 433
IF: Data Selection Statement ...................................................................................................... 435
ON Statement: Data Selection Statement ..................................................................................... 438
ON CLASS: Data Selection Statement .......................................................................................... 445
ON COMPARE: Data Selection Parameter ..................................................................................... 448
ON DATA: Data Selection Statement............................................................................................ 458
ON DB2: Data Selection Statement .............................................................................................. 461
ON DDNAME: Data Selection Statement....................................................................................... 465
ON DSN: Data Selection Statement ............................................................................................. 467
ON FILE: Data Selection Statement ............................................................................................. 469
ON PAGE: Data Selection Statement ............................................................................................ 471
ON SYSDATA: Data Selection Statement ...................................................................................... 474
ON SYSOUT: Data Selection Statement ........................................................................................ 477
ON VSAM: Data Selection Statement ........................................................................................... 480
OPTIONS: Basic Rule Parameter .................................................................................................. 484
OWNER: Basic Rule Parameter .................................................................................................... 485
UPDATED... BY: Basic Rule Parameter ......................................................................................... 487
WHEN: Rule Definition Structure ................................................................................................. 488
Rule Definition Using an Editor .................................................................................................... 507

8
Rule Definition Structure ............................................................................................................. 508
Language Syntax ........................................................................................................................ 510
Command Reference .................................................................................................................. 511
Rule Definition Process Examples ................................................................................................ 521

Mission Definition Parameters ...................................................................................... 527


Mission Definition Parameters ..................................................................................................... 528
Parameter Descriptions ............................................................................................................... 534
CATEGORY: Mission Definition Parameter .................................................................................... 535
CONFCAL: Mission Definition Parameter ....................................................................................... 537
DATES: Mission Definition Parameter ........................................................................................... 540
DAYS: Mission Definition Parameter............................................................................................. 542
DESC: Mission Definition Parameter ............................................................................................. 550
DOCLIB: Mission Definition Parameter ......................................................................................... 552
DOCMEM: Mission Definition Parameter ....................................................................................... 554
GROUP: Mission Definition Parameter .......................................................................................... 556
IN: Mission Definition Parameter ................................................................................................. 558
JOB: Mission Definition Parameter ............................................................................................... 561
MAXWAIT: Mission Definition Parameter ...................................................................................... 563
MINIMUM: Mission Definition Parameter ...................................................................................... 566
MISSION: Mission Definition Parameter ....................................................................................... 568
MONTHS: Mission Definition Parameter ....................................................................................... 570
NOT LATER THAN: Mission Definition Parameter .......................................................................... 571
OWNER: Mission Definition Parameter ......................................................................................... 573
PDS: Mission Definition Parameter ............................................................................................... 575
PRIORITY: Mission Definition Parameter ...................................................................................... 577
RETRO: Mission Definition Parameter .......................................................................................... 578
RULELIB: Mission Definition Parameter ........................................................................................ 581
RULENAME: Mission Definition Parameter .................................................................................... 582
SCOPE: Mission Definition Parameter ........................................................................................... 583
SET VARS: Mission Definition Parameter ...................................................................................... 586
STEP: Mission Definition Parameter ............................................................................................. 587
TIME: Mission Definition Parameter ............................................................................................. 589
WDAYS: Mission Definition Parameter.......................................................................................... 592

Reconciliation Facility .................................................................................................. 600


Reconciliation Facility .................................................................................................................. 600
Reconciliation Stages .................................................................................................................. 601
Reconciliation Work Flow ............................................................................................................ 603

9
Activating Program CTBRECL ...................................................................................................... 603
Reconciliation Functions .............................................................................................................. 604
DD Statements ........................................................................................................................... 621
Return Codes ............................................................................................................................. 622

Report Generation ...................................................................................................... 625


Report Types ............................................................................................................................. 625
Rule Activity Report .................................................................................................................... 625
Dynamic Print Formatting Facility................................................................................................. 626

Rollback Facility.......................................................................................................... 627


Control-M/Analyzer Rollback Facility ............................................................................................ 627
Activating the Rollback Facility .................................................................................................... 628
Triggering the Rollback Facility through Control-M/Restart ............................................................ 629
Viewing Deleted Variable Generations .......................................................................................... 630
Displaying Rollback Results ......................................................................................................... 631

Control-M/Analyzer Interfaces ..................................................................................... 632


Control-M/Analyzer Interfaces ..................................................................................................... 632
Interface to Control-M ................................................................................................................ 633
Control-M Job Definition Screen Format ....................................................................................... 636
Interface to Control-D and Control-V ........................................................................................... 637
Interface to User Programs ......................................................................................................... 640

Solveware Samples Kit ................................................................................................ 643


General...................................................................................................................................... 643
SolveWare Samples .................................................................................................................... 644
Implementation Steps................................................................................................................. 644
Sample Rules ............................................................................................................................. 645

A Editing Rule Definitions in the IOA Edit Environment................................................. 660


Line Editing Command Subjects .................................................................................................. 661
Line Editing Commands .............................................................................................................. 662
Maintaining Valid Rule Definitions ................................................................................................ 664
Examples ................................................................................................................................... 665

10
B Reserved Words .................................................................................................... 673

C Calling Control-M/Analyzer User Routines ................................................................ 675


Loading the User Routine into Memory ........................................................................................ 675
Register Usage ........................................................................................................................... 676
Argument Pointers ...................................................................................................................... 677

D Euro Support ........................................................................................................ 678


Euro Support Objectives ............................................................................................................. 678
Method of Operation................................................................................................................... 678
Implementing Euro Currency Support .......................................................................................... 679

E TRACE Facility ....................................................................................................... 687


Activating the TRACE facility ....................................................................................................... 687
Applying the TRACE facility to a rule ............................................................................................ 687

F Single Startup API.................................................................................................. 689


Runtime Environment – Description ............................................................................................. 689
API Documentation .................................................................................................................... 690
Execution Logic .......................................................................................................................... 691
Examples ................................................................................................................................... 692

11
About this guide
Control-M/Analyzer is a component member of the INCONTROL™ by BMC family of products. This guide is
the basic publication on how to use Control-M/Analyzer software. It should be used by any person who
wants to verify and balance data using Control-M/Analyzer.
This guide contains detailed information about Control-M/Analyzer functions and facilities, and contains
the following chapters:
Introduction (on page 19)
An overview of Control-M/Analyzer. Introducing key concepts used by Control-M/Analyzer, this chapter
provides an overall description of the Control-M/Analyzer balancing environment and its integration into
your operations environment. BMC recommends that this chapter be read before proceeding to other
chapters.
Online Facilities (on page 58)
A walkthrough guide to using online facilities. Control-M/Analyzer and IOA screens are displayed and
discussed in a logical sequence. This chapter describes the Control-M/Analyzer user interface while
introducing the user to Control-M/Analyzer concepts and terminology.
Control-M/Analyzer Variables (on page 222)
Building on concepts learned in the preceding chapters, the user is introduced to the various types of
variables provided by Control-M/Analyzer. Variables are used to store and access information during data
balancing tasks (rules). Included in this chapter is a detailed discussion of the Control-M/Analyzer
database, which is accessed using the Online facility, and a list of Control-M/Analyzer system variables.
The AutoEdit facility and use of AutoEdit variables are also discussed in this chapter.
Expressions and Functions (on page 269)
Expressions enable the user to perform calculations and data comparisons. Included in this chapter is a
list of built-in functions provided by Control-M/Analyzer.
Rule Definition (on page 348)
Rules can be created by specifying parameters using the Online facility. Detailed information about, and
examples of, each rule definition parameter are provided in this chapter.
Rules can also be created using a standard editor. Detailed information on Control-M/Analyzer rule
language syntax and commands is provided in this chapter.
Mission Definition Parameters (on page 527)
Missions are used to schedule data balancing tasks (rules). Missions are defined and created using the
Online facility. Detailed information about each mission definition parameter is provided in this chapter.
Reconciliation Facility (on page 600)
Data from different sources can be compared and balanced with the Reconciliation facility. Comparisons
can be made across applications and between different generations of the same application.
Report Generation (on page 625)
Describes the types of reports available under Control-M/Analyzer.

12
Rollback Facility (on page 627)
Instructions for restoring the Control-M/Analyzer Database to a previous state are provided in this
chapter.
Control-M/Analyzer Interfaces (on page 632)
Information regarding accessing and interfacing with other INCONTROL products and user programs is
provided in this chapter.
Solveware Samples Kit (on page 643)
Sample rules illustrate Control-M/Analyzer balancing techniques and methods. These rules can help you
implement Control-M/Analyzer quickly and successfully.
A Editing Rule Definitions in the IOA Edit Environment (on page 660)
Explains how to perform line editing commands from within the IOA Edit environment.
B Reserved Words (on page 673)
Lists words that are reserved by Control-M/Analyzer for its own use, and that should not be specified
when naming rules, missions, variables, and so on.
C Calling Control-M/Analyzer User Routines (on page 675)
Provides technical information that describes how user routines are called.
D Euro Support (on page 678)
Enables Control-M/Analyzer rules to validate data before and after implementing Euro currency conversion
in data and/or application software.
E TRACE Facility (on page 687)
Examines Control-M/Analyzer commands while a rule is executing and after its termination.
F Single Startup API (on page 689)
Enables a user program to make multiple calls to a Control-M/Analyzer rule after performing a single
startup of the Control-M/Analyzer Runtime environment.

13
Conventions Used in this Guide
Notational conventions that may be used in this guide are explained below.

Standard Keyboard Keys


Keys that appear on the standard keyboard are identified in boldface, for example, Enter, Shift, Ctrl+S
(a key combination), or Ctrl S (a key sequence).
The commands, instructions, procedures, and syntax illustrated in this guide presume that the keyboards
at your site are mapped in accordance with the EBCDIC character set. Certain special characters are
referred to in this documentation, and you must ensure that your keyboard enables you to generate
accurate EBCDIC hex codes. This is particularly true on keyboards that have been adapted to show local
or national symbols. You should verify that
$ is mapped to x'5B'
# is mapped to x'7B'
@ is mapped to x'7C'
If you have any questions about whether your keyboard is properly mapped, contact your system
administrator.

Preconfigured PFKeys
Many commands are preconfigured to specific keys or key combinations. This is particularly true with
regard to numbered PF keys, or pairs of numbered PF Keys. For example, the END command is
preconfigured to, and indicated as, PF03/PF15. To execute the END command, press either the PF03 key
or the PF15 key.
Instructions to enter commands may include
 only the name of the command, such as, enter the END command
 only the PF keys, such as, press PF03/PF15
 or both, such as, press PF03/PF15, or enter the END command

Command Lines and Option Fields


Most screens contain a command line, which is primarily used to identify a single field where commands,
or options, or both, are to be entered. These fields are usually designated COMMAND, but they are
occasionally identified as COMMAND/OPT or COMMAND/OPTION.
Option field headings appear in many screens. These headings sometimes appear in the screen examples
as OPTION, or OPT, or O.

14
Names of Commands, Fields, Files, Functions, Jobs, Libraries,
Members, Missions, Options, Parameters, Reports,
Subparameters, and Users
The names of commands, fields, functions, jobs, libraries, members, missions, options, parameters,
reports, subparameters, users, and most files, are shown in standard UPPERCASE font.

User Entries
In situations where you are instructed to enter characters using the keyboard, the specific characters to
be entered are shown in this UPPERCASE BOLD text, for example, type EXITNAME.

Syntax statements
In syntax, the following additional conventions apply:
 A vertical bar ( | ) separating items indicates that you must choose one item. In the following
example, you would choose a, b, or c:

a | b | c
 An ellipsis ( . . . ) indicates that you can repeat the preceding item or items as many times as
necessary.
 Square brackets ( [ ] ) around an item indicate that the item is optional. If square brackets ( [ ] ) are
around a group of items, this indicates that the item is optional, and you may choose to implement
any single item in the group. Square brackets can open ( [ ) and close ( ] ) on the same line of text,
or may begin on one line of text and end, with the choices being stacked, one or more lines later.
 Braces ({ }) around a group of items indicates that the item is mandatory, and you must choose to
implement a single item in the group. Braces can open ( { ) and close ( } ) on the same line of text,
or may begin on one line of text and end, with the choices being stacked, one or more lines later.

Screen Characters
All syntax, operating system terms, and literal examples are presented in this
typeface. This includes JCL calls, code examples, control statements, and system messages. Examples
of this are:

15
 calls, such as
CALL 'CBLTDLI'

 code examples, such as


FOR TABLE owner.name USE option, . . . ;

 control statements, such as


//PRDSYSIN DD * USERLOAD PRD(2) PRINT

 system messages, both stand-alone, such as You are not logged on to database
database_name, and those embedded in text, such as the message You are not logged on to
database database_name, are displayed on the screen.

Variables
Variables are identified with italic text. Examples of this are:
 In syntax or message text, such as
Specify database database_name
 In regular text, such as
replace database database_name1 with database database_name2 for the current session
 In a version number, such as
EXTENDED BUFFER MANAGER for IMS 4.1.xx

Special elements
This guide includes special elements called notes and warnings:
Notes provide additional information about the current subject.
Warnings alert you to situations that can cause problems, such as loss of data, if you do not follow
instructions carefully.

Information New to this Version


Additional information that is new to this version is described in the INCONTROL for z/OS Installation
Guide: Upgrading and the What’s New section of the INCONTROL for z/OS Release Notes.

Information Relating to Control-M/Restart Users


Certain information presented in the guide is relevant only to Control-M users who have Control-M/Restart
installed at their site.
Note: Control-M/Restart was called Control-R in earlier versions.

16
Control-M/Restart information is identified in this guide by the §Restart§ symbol, which is shown at the
beginning of the Control-M/Restart information. This symbol is shown using the following guidelines:
 If an entire topic level is dedicated to Control-M/Restart material, the heading of that topic begins
with the §Restart§ symbol. Similarly, if there are lower level topics within that level that are also
dedicated to Control-M/Restart material, the headings of those lower level topics will also begin with
the §Restart§ symbol.
This provision also applies to Control-M/Restart paragraphs, each of which will begin with the
§Restart§ symbol, or, on occasion, to single sentences, or even phrases or words, if they exclusively
pertain to Control-M/Restart material.
 The same §Restart§ symbol is placed at the conclusion of each unbroken block of text material that
contains Control-M/Restart material, regardless of whether the material spans more than one heading
level, paragraph, or sentence. For example, if a first level Control-M/Restart topic includes second
and/or third and/or fourth and/or fifth level topic headings, with no intervening material that is not
related to Control-M/Restart, the §Restart§ symbol will be placed at the end of the text in the lowest
level sentence of unbroken Control-M/Restart material.
 If a figure or table is used exclusively to identify or explain Control-M/Restart material, the following
statement will appear immediately preceding the figure title or the table title:
§Restart§ The following (figure)(table) is for users who have Control-M/Restart installed at their
site.
 If Control-M/Restart material is included only in part of a figure or table otherwise used to illustrate
standard Control-M material, the §Restart§ symbol will be used within the figure or table to identify
the information relevant only to Control-M/Restart users.
If Control-M/Restart is not installed at your site, you can skip any material in this guide that is identified
with the §Restart§ symbol.

Related Publications
INCONTROL for z/OS Installation Guide
A step-by-step guide to installing, customizing, maintaining, and upgrading INCONTROL products using
the INCONTROL Customization and Installation Engine (ICE) application.
The guide is divided into the following volumes:
 INCONTROL for z/OS Installation Guide: Installing
This guide describes the procedures and steps required for installing INCONTROL products.
The following installation tracks are available:
• express installation
• customized installation
• cloning
 INCONTROL for z/OS Installation Guide: Customizing
This guide describes the procedures and steps required for customizing INCONTROL products.

17
 INCONTROL for z/OS Installation Guide: Maintaining
This guide describes the procedures and steps required for maintaining INCONTROL products.
The following maintenance procedures are described:
• periodic maintenance
• ad hoc maintenance
• change deployment
 INCONTROL for z/OS Installation Guide: Upgrading
This guide contains instructions for upgrading to the current release from previous INCONTROL
versions.
The Express Upgrade is the recommended approach for upgrading INCONTROL products to the most
recent major version.

INCONTROL for z/OS Messages Manual


A comprehensive listing and explanation of all IOA and INCONTROL messages.

INCONTROL for z/OS Administrator Guide


This guide provides information for system administrators about customizing and maintaining INCONTROL
products.

INCONTROL for z/OS Security Guide


Step-by-step guide to implementing security in INCONTROL products using the ICE application. Security
guides are currently available for IOA interaction with RACF, CA-TOP SECRET and CA-ACF2.

INCONTROL for z/OS Utilities Guide


A detailed description of the utilities designed to perform specific administrative tasks that are available to
INCONTROL products. The guide contains an alphabetized reference of all utilities for each INCONTROL
product.

User Guides
Product-specific guides containing comprehensive information about the operation and implementation of
each INCONTROL product.

18
1
1
Introduction
This chapter includes the following topics:
 INCONTROL Products and IOA (on page 20)
• IOA (on page 21)
• INCONTROL (on page 21)
 Control-M/Analyzer Capabilities (on page 23)
 Data Types (on page 24)
 Automated Actions (on page 25)
 Unattended Balancing Operations (on page 26)
 Extended IOA Capabilities (on page 26)
 Control-M/Analyzer Quality Control (on page 26)
• Manual Quality Control of Computer Processes (on page 27)
• Automated Quality Control of Computer Processes With Control-M/Analyzer (on page 27)
 How Control-M/Analyzer Works (on page 29)
 Methods of Invoking Control-M/Analyzer (on page 30)
 Input Data Sources (on page 30)
 Control-M/Analyzer Runtime Environment (on page 31)
 Balanced Data (on page 32)
 Job Flow Under Control-M/Analyzer (on page 32)
 Control-M/Analyzer Implementation (on page 33)
• Defining Groups (on page 33)
• Group Concept and Group Modes (on page 33)
• Collecting Information (on page 35)
• Using the Online Facility (on page 35)
• Defining Database Variable Parameters (on page 35)
• Defining Rule Parameters (on page 36)
• Defining Balancing Mission Parameters (on page 39)
• Balancing Mission Definition Screen (on page 40)
 Invoking the Control-M/Analyzer Runtime Environment (on page 41)
• General (on page 41)
• Invoking Control-M/Analyzer Directly (on page 42)

19
Control-M/Analyzer User Guide

• Passing Arguments While Invoking Control-M/Analyzer (on page 42)


• Invoking Control-M/Analyzer With Balancing Missions (on page 44)
 Control-M/Analyzer Components (on page 46)
• Overview (on page 47)
• Mission and Rule Definition Libraries (on page 49)
• Online Definition, Tracking, and Control Facility (on page 49)
• New Day Procedure (on page 50)
• Reporting Facility (on page 51)
• Utilities (on page 52)
 IOA Environment (on page 52)
 Prerequisite Condition Concept (on page 52)
 IOA Calendar Facility (on page 54)
 Date Definition Concepts (on page 55)
• System Date (on page 55)
• Working Date (on page 55)
• Original Scheduling Date (on page 56)
• Date Standards and Date Field Formats (on page 56)

INCONTROL Products and IOA


The Control-M/Analyzer Automated Information Integrity System is a component member of the
INCONTROL family of products, a fully integrated suite designed to automate, manage and streamline
operations on the z/OS mainframe. The INCONTROL family also includes client/server products that
facilitate the automation of other platforms.
The following table lists name changes as of version 6.1.00 for the following products:
Table 1 Product Name Changes as of INCONTROL Version 6.1.00

Product Name as of version 6.1.00 Product Name prior to version 6.1.00

Control-M/Analyzer Control-B

Control-M/Enterprise Manager Enterprise Controlstation

Control-M/Restart Control-R

Control-M/Tape Control-T

20
Control-M/Analyzer User Guide

IOA
The Integrated Operations Architecture (IOA) is at the heart of the INCONTROL family of products. IOA
has a common core of shared code as the foundation of its architecture design. INCONTROL's IOA
environment has several inherent design advantages, including a common user interface and a shared
data repository. A key feature of the IOA environment is its integrated application design, which includes:
 Integrated User Notification
 Management by Exception
 Integrated Scheduling
 Interdependency and Interrelationship Handling
 Common Help Facility
 Integrated Management Reporting
 Common Method for Sharing Information
 Unified Installation and Maintenance
 Unified Security Implementation
 Open Interface Design

INCONTROL
The INCONTROL family of products includes:
Table 2 List of INCONTROL Products

Product Description

Control-M Automated Production Control and Scheduling System


Manages and automates the setup, scheduling and execution
of jobs in the data center.

Control-M/Restart Restart Management System


Automates the activities that must be performed when
restarting failed jobs, including the scratching and
uncataloging of data sets created by failed jobs.

Control-M/Tape Removable Media Management System


Increases utilization of removable media and controls
retention periods. Prevents misuse of media, and provides
tape library and vault control.

Control-M/Analyzer Automated Information Integrity System


Performs in-stream validation, accuracy, and reasonability
checks on information used by data center production tasks
(for example, reports, databases).

21
Control-M/Analyzer User Guide

Product Description

Control-D Output Management System Automatically schedules and


controls every aspect of report processing and distribution,
including report decollating, bundling, printing, online viewing,
and archiving.

Control-V Quick Access Archive Viewing System


Provides online access to archived reports and documents by
indexed data retrieval.

Control-D/ Report Retrieval and Display System


Page On Demand Enables end users to retrieve and view pages of reports that
reside on mainframe storage in real time. Indexed reports can
be retrieved by index name and value. AFP and XEROX
reports can also be retrieved and displayed using
Control-D/WebAccess Server or Control-D/Page On Demand
API.

Control-D/ Image Image Output Management System


Enables output from commercial imaging equipment to be
imported into either Control-D or Control-V for decollation,
distribution and viewing, and into Control-V for archiving and
indexed retrieval.

Control-O Console Automation System and Desired State Monitoring


System
Monitors and automatically responds to messages, commands,
and data set events, as well as various other system events.
The Control-O/COSMOS feature allows for status monitoring
while maintaining all critical system objects in a desired and
ideal status.

22
Control-M/Analyzer User Guide

Control-M/Analyzer Capabilities
Control-M/Analyzer is a data balancing and quality control system that is designed to do the following:
 perform data balancing (examining, checking, verifying information integrity) for applications and
other production processes
 automatically react to potential crisis situations before corrupted data is dispersed throughout the
system
 reduce the cost of correcting data related problems by detecting and fixing them as soon as possible
 provide quality control during job execution, reducing the need for and delay caused by manual
checking
 influence an existing job flow based on balancing results
 rollback Control-M/Analyzer Database values to an earlier generation if necessary
Control-M/Analyzer can be invoked in the following ways:
 by inserting a Control-M/Analyzer step within a job
Several Control-M/Analyzer steps can be inserted within a job. Control-M/Analyzer steps can be
inserted before and after an existing job step, enabling data validation both before and after the
execution of a production step. Input data is validated before a step is executed, and output data is
examined and balanced after a step is executed.
Because Control-M/Analyzer steps can be placed inside a job, Control-M/Analyzer provides monitoring
and intervention at any point in the job. Results of a Control-M/Analyzer step can influence the
execution of subsequent job steps.
 directly from an application program
Arguments can be passed from the application program to Control-M/Analyzer (for validation,
balancing, or storage for future use). Control-M/Analyzer can also return values to the application
program, including balancing results.
 by another product in the INCONTROL family of products

23
Control-M/Analyzer User Guide

Data Types
Various types of data can be selected, analyzed and balanced. Types of data that may be specified in
Control-M/Analyzer include:
Table 3 Data Types

Data Description

Files Sequential data sets (including partitioned data set


members).

CDAM files Compressed Data set Access Method files created by


Control-D.

DB2 tables Information extracted from DB2 tables using SQL


statements.

VSAM files Information extracted from VSAM files.

Outputs Outputs of a specific sysout held class, destination, external


writer, form, or DD name.

DD statements DD statements in the current job step.

Control-D output Output reports created by Control-D.

Control-M SYSDATA The three Control-M job sysout data sets (archived by
Control-M/Restart): job log (console messages), expanded
JCL, and system output messages.

Control-M/Analyzer generated Control-M/Analyzer System, Local and Database variables.


and stored data

Other user-defined data Various predefined site-specific types of data.


sources

24
Control-M/Analyzer User Guide

Automated Actions
Control-M/Analyzer offers a wide range of automated actions that aid in balancing data and in performing
operations as a result of the balancing process. Some of these actions include:
Table 4 Automated Actions

Action Description

Data Search and Search data sources for critical information. Extract data for
Extraction examination and manipulation. Store extracted data for later use.

Data Manipulation Perform calculations and data manipulation functions to determine


balancing results.

Database Access Retrieve data from the Control-M/Analyzer Database and store
calculations and data for future reference in the Database.
Cross-reference Database variables and the rules that use them.

Data Reconciliation Reconcile data from different sources. Produce summary records for
large files by data reconciliation.

Formatted Reports Format printed values so that numbers and text are positioned
within an output field according to your specifications.

Job Output Process job sysout information.

Rule Processing Control rule processing flow based on conditional criteria – invoke
Control Flow certain statements and skip other statements.

User Notification Issue user notification messages to various destinations upon the
occurrence of specified events.

Issuance of Balancing Issue balancing results in meaningful terminology – OK, TOLER, and
Results NOTOK.

Job Execution Control Issue appropriate codes to discontinue the processing of a job if the
data are not balanced.

Report Control Influence report processing (for example, releasing, deleting, and
changing class or destination) based on balancing results.

Euro Support Enables Control-M/Analyzer rules to validate data before and after
implementing Euro currency conversion in data and application
software.

25
Control-M/Analyzer User Guide

Unattended Balancing Operations


 Balancing tasks are fully automated.
 Data balancing tasks (rules) are automatically scheduled.
 Calendars that dynamically schedule all balancing activities can be created.
 Steps are inserted within the JCL of a job for direct rule invocation.

Extended IOA Capabilities


Since Control-M/Analyzer incorporates the Integrated Operations Architecture (IOA) features of the
INCONTROL family of products, Control-M/Analyzer capabilities extend into, influence, and are influenced
by other INCONTROL products.
Prerequisite conditions automate the scheduling of events between INCONTROL products. The user can
establish dependencies between rules and between a rule and other environments.
Control-M/Analyzer can assign values to a variable, and store values in the Control-M/Analyzer Database.
These values can be made globally available to other Control-M/Analyzer rules. AutoEdit variables saved
in a symbol member can also be referenced later by other INCONTROL products.
Control-M/Analyzer balancing analysis can automatically trigger controlled job scheduling under
Control-M, as well as affect the processes of other INCONTROL products. Control-M/Restart can trigger
the Control-M/Analyzer Rollback Facility.
Control-M/Analyzer can process CDAM data sets.
Other INCONTROL products can also initiate rules in Control-M/Analyzer and use the results of these rules
to determine further processing.
The integrated IOA environment, and resultant synchronization between INCONTROL products, provides
virtually unlimited automated operations capabilities.

Control-M/Analyzer Quality Control


Quality control of computer processes requires physical examination of report input/output from each
application job, text checking, and posting and crosschecking counts and totals. These "checks and
balances" have to occur on a regular basis so that data integrity is guaranteed.

26
Control-M/Analyzer User Guide

Manual Quality Control of Computer Processes


The manual performance of data balancing procedures is a slow, tedious, labor-intensive, error-prone
process:
 Because data balancing tasks are scheduled manually, some tasks may not be performed at the
correct time or at all. If quality control balancing is not performed on time, errors go undetected and
entire applications may have to be rerun.
 Errors can easily be made when manually performing data balancing tasks.
 Manual checking of "sensitive" data may require the time of highly paid professionals who are not
always available (due to vacation, illness, and so on). Moreover, manual balancing is a clerical task
that most professionals would rather not have to do.
 The usage of output produced at night or on weekends may be delayed until manual checking can be
performed during the next working day.
 When erroneous data is found, other persons have to be manually notified to take various corrective
actions.
The diagram below illustrates the daily flow of manual quality control of computer processes. For each
job, scheduling and processing of data balancing tasks are usually performed for both job input and job
output. Without Control-M/Analyzer, all balancing tasks are performed manually. The result is often "too
little, too late" and the consequences may be expensive, embarrassing, or both.
Figure 1 Daily Flow of Manual Quality Control of Computer Processes

Automated Quality Control of Computer Processes With


Control-M/Analyzer
Immediate detection of data-related processing errors is provided by Control-M/Analyzer. The
Control-M/Analyzer detection capabilities automatically respond to error situations before corrupted data
are dispersed throughout the system.
When scheduling and data balancing procedures are automated, the operations environment becomes
more efficient, productive, and accurate. Large amounts of time are freed up for other tasks.
The diagram below illustrates the daily flow of automated quality control of computer processes with
Control-M/Analyzer. For each job, scheduling and processing of data balancing tasks is usually performed
for both job input and job output. With Control-M/Analyzer, these tasks are performed automatically.
Simply run the job, and data balancing tasks are performed for you.

27
Control-M/Analyzer User Guide

Figure 2 Daily Flow of Automated Quality Control of Computer Processes

Control-M/Analyzer data balancing procedures can implement a wide variety of quality control techniques
including:
 internal consistency checks
 cross-application checks
 run-to-run comparisons and trend analysis
 statistical evaluations
With Control-M/Analyzer, data balancing need not require changes to program source code. Incorporating
sophisticated quality control techniques in the source code of numerous programs is time-consuming,
expensive and, if your organization does not control the source code, simply impossible.
When problems are detected, Control-M/Analyzer can initiate one or more of the following appropriate
actions:
 terminate with a return code that indicates the type of problem
 initiate the execution of a job or application
 continue or stop subsequent production jobs and reports
 send messages to appropriate recipients
 open problem tickets
 delete a problematic report file from spool
 produce a detailed balancing report indicating the number and types of problems found
The Control-M/Analyzer Reconciliation Facility provides a quick and effective way to determine why
control totals do not balance. This facility examines multiple information sources, sorts them, compares
them on the record level, and identifies specific records that do not match. The Reconciliation facility
enables extraction, reformatting, accumulation and comparison of data fields in files. Any field or
combination of fields can be defined as a key for sorting the records prior to comparison.

28
Control-M/Analyzer User Guide

How Control-M/Analyzer Works


The following overview describes how Control-M/Analyzer integrates into your production environment.
The overview consists of the following four topics:
 methods of invoking Control-M/Analyzer
 input data sources
 Control-M/Analyzer Runtime environment
 balanced data
These topics are presented in the form of a graphic illustration (called the Control-M/Analyzer Runtime
Environment) in Figure 3.
Production jobs are scheduled and run by operations staff on a daily basis. Jobs process various types of
data sources. The data integrity of these data sources can be automatically checked and verified using
Control-M/Analyzer.
The illustration represents Control-M/Analyzer within your production environment. According to the
illustration, the balancing process is initiated by an Invocation Method (A), which is represented by an
ON/OFF switch. This switch activates a conveyer belt that loads diamonds into a balancing machine. The
various input data sources (B) that can be balanced by Control-M/Analyzer are represented by diamonds.
The Control-M/Analyzer Runtime Environment (C) that performs all balancing operations is diagrammed
as a machine. Based on instructions specified by the Online Definition, Tracking, and Control facility (D)
and stored in Definition libraries in the Repository (E), each data source is examined. The balancing
operation is represented by a scale, which determines if each diamond is OK, TOLER, or NOTOK.
Control-M/Analyzer guarantees that data in your production environment are balanced according to
standards you define. The Balanced Data (F) is represented by tagged diamonds. Data that are not within
reasonable tolerance limits can be rejected by your production system.
Figure 3 Control-M/Analyzer Overview

29
Control-M/Analyzer User Guide

Methods of Invoking Control-M/Analyzer


Methods of invoking the Runtime environment are depicted as the ON/OFF switch to the data input
conveyer belt. The Runtime environment can be invoked by application programs directly, or by adding a
Control-M/Analyzer step to a job, or by a call from another INCONTROL product.
When Control-M/Analyzer is invoked by a job step, after all balancing tasks have terminated, a value can
be returned to the job, indicating whether the data source is valid, and whether the job should continue
processing.
Scheduling criteria and balancing instructions are specified in the step that invokes Control-M/Analyzer.

Input Data Sources


In Figure ,3 data sources that await balancing are represented by diamonds, that are loaded onto a
conveyer belt. These diamonds must be weighed and analyzed to determine their true worth. Similarly,
data sources need to be analyzed to determine their accuracy and validity.
For a list of available data sources, seeData Types (on page 24).
Data source validity can be categorized as shown in Table 5.
Table 5 Data Source Validity

Validity Description

OK Valid

TOLER Not valid, but within user-specified tolerance limits

NOTOK Invalid

30
Control-M/Analyzer User Guide

Control-M/Analyzer Runtime Environment


The Runtime environment in Figure 3, in How Control-M/Analyzer Works (on page 29), is the mechanism
that performs balancing procedures according to your specifications and standards. These standards are
contained in rules and missions.
Table 6 Runtime environment rules and missions

Item Description

Rules Specify all balancing instructions and criteria. Rules inform


Control-M/Analyzer exactly how to balance the information.

Missions Specify scheduling criteria that permit different balancing activities


based on time/event dependencies.

The data source is examined and processed by the rule. During rule processing, calculations are
performed to determine if the data source is balanced. Information can be stored in variables for future
use, facilitating "run-to-run" and "cross-application" comparisons and checking.
The Runtime environment can be monitored and controlled by the Online Definition, Tracking, and Control
facility as shown in Figure 3. This Online facility enables you to view and control Control-M/Analyzer
Definition libraries, and various files stored in the Control-M/Analyzer Repository, as shown in Figure .3
The tracking screens provided by the Online facility include:
Table 7 Tracking Screens

Screen Description

Active Balancing Displays daily status information about missions/rules (for


Environment Screen example, which rules are currently executing).

Rule Activity Display Provides access to historical information about Control-M/Analyzer


invocations, including Control-M/Analyzer reports, committed
variable values, and Log information.

Database Variable Displays generation information and values of Database variables.


Display

For each tracking screen, options and commands provide additional control over the displayed
information.

31
Control-M/Analyzer User Guide

Balanced Data
The diamonds in the illustration in Figure 3, in How Control-M/Analyzer Works (on page 29), are tagged
according to the value determined by the machine after the analysis process. Similarly, the Runtime
environment determines which data sources are accurate and valid. Data that successfully complete the
balancing process are called Balanced Data.
Balancing results are returned to the rule and to the production job/application program. Using these
balancing results and the JCL "COND" mechanism, execution of subsequent steps in the job can be
controlled. In this manner, valid data sources continue to be processed in the production environment,
while invalid data sources can be rejected. Rejecting invalid data sources is symbolized by the ejection of
NOTOK diamonds from the machine.

Job Flow Under Control-M/Analyzer


The following is a brief description of the daily job flow using Control-M/Analyzer:
 Each day, the New Day procedure is run. The New Day procedure analyzes balancing mission
definitions to decide whether missions are candidates for execution on a specific date (meaning, are
scheduled to be invoked on that day). The selected balancing missions are placed in the Active
Balancing file.
 Jobs are run according to the normal production schedule. When the Control-M/Analyzer Runtime
environment is invoked (for example, by a job step, or a call from a user program), the Active
Balancing file is scanned for a matching mission entry. For additional information see Invoking
Control-M/Analyzer With Balancing Missions (on page 44). Control-M/Analyzer invokes the rule that is
specified by the matching entry. If the Runtime environment was invoked with a rule name instead of
a mission name, the specified rule is invoked. At this point, the appropriate rule is activated, based on
prerequisite conditions and time constraints.
 The calculations, functions, and data comparisons specified by the rule definition are performed on
the data, using Database and other variables if indicated.
 When a balancing decision is reached, the following actions, among others, may be performed:
• Prerequisite conditions are added and deleted, thereby triggering other events or missions in the
production environment.
• Messages are sent to specified destinations through the Shout facility.
• Jobs are terminated based on the result of their balancing mission or rule. Execution of
subsequent job steps (as in standalone mode) can be determined as well.

32
Control-M/Analyzer User Guide

 Job sysouts, Rule Activity reports, and online tracking screens enable balancing results to be
examined.
 The Control-M/Analyzer sysout files shown in Table 8 are created after rule termination.
Table 8 Sysout Files

File Description

SYSPRINT This member contains information about the rule invocation,


including the Rule Activity report. The Rule Activity report can also
be viewed by specifying the R option in the Rule Activity display.

SYSRULE This member contains a listing of the rule definition.

SYSUSER This sysout contains the output of all DO PRINT statements


specified in the rule definition.

Control-M/Analyzer Implementation
This overview provides recommendations regarding preparations for implementing Control-M/Analyzer.
For an in-depth discussion of Control-M/Analyzer implementation, see the INCONTROL for z/OS
Installation Guide, the INCONTROL for z/OS Administrator Guide, and the Control-M/Analyzer Getting
Started and Implementation Guide.

Defining Groups
BMC recommends that you divide the workplace into logical groups and applications (for
example, accounting department, managers). Control-M/Analyzer operates on a group basis, and
balancing tasks can be different for each group. Also, different groups can be implemented using a
"staged implementation" strategy and become fully operational at different times based on Group
Implementation Modes.

Group Concept and Group Modes


All Control-M/Analyzer jobs with data that needs balancing are categorized into groups. Jobs within the
same group usually have a common purpose. Control-M/Analyzer groups are functional in nature; they
represent logical categories that reflect actual divisions in your workplace. Some typical groups are:
ACCOUNTING, INVENTORY, MIS_DEPT.
The group concept provides several important features, as shown in Table 9.

33
Control-M/Analyzer User Guide

Table 9 Features of Group Concepts and Modes

Feature Description

Control-M/Analyzer Usually, jobs that perform similar functions need access to the
Database variables same type of information. For example, quality control jobs
need to access different Control-M/Analyzer Database
variables than payroll jobs.
Control-M/Analyzer assumes that the Database variable being
referenced belongs to the current group. There is no need to
specify the group name. However, it is possible to define a
rule that accesses Database variables of other groups.

Rule Activity screen Control-M/Analyzer rule invocations can be listed by group.


Only relevant rule invocations are shown, providing quick
access to needed information (for example, their invocation
reports).

IOA Log file The audit trail in the IOA Log file may be listed by group,
providing a meaningful list of audit trail entries.

Implementation modes Rules can be tested and implemented by group by specifying


an implementation mode. The following modes are provided
by Control-M/Analyzer:
 Define mode - Rules and variables of a group under
Define mode are not processed by Control-M/Analyzer.
Control-M/Analyzer automatically returns an OK result.
This mode is especially useful when initially developing
and inputting new rules and variables.
 Simulate mode - Simulate mode instructs
Control-M/Analyzer to process rules and report on
balancing results without taking action. This mode enables
the testing of rules without impacting the production
environment. Online and batch action reports are
produced detailing the outcome of the evaluation, but
actual reaction processing (for example, committing
Control-M/Analyzer variables, adding new prerequisite
conditions) is suppressed. This mode is especially helpful
during system testing and rule debugging.
 Active Mode - Active mode is the production mode for
Control-M/Analyzer rules. In Active mode, data are
evaluated and all actions defined by the user are taken.

34
Control-M/Analyzer User Guide

Collecting Information
After your workplace has been divided into logical groups and applications, relevant examples of the data
sources that need balancing should be collected. Various comparisons and calculations that need to be
performed, and the values that should be stored in the Control-M/Analyzer Database, are listed for future
reference.

Using the Online Facility


The Online facility is used to define Database variables, rules, and missions. This topic describes the
definition screens.

Defining Database Variable Parameters


Control-M/Analyzer Database variables are stored in the Control-M/Analyzer Database. These variables
may be accessed by any Control-M/Analyzer rule at any time. When a rule processes data, it can save
values in the Database for future use by other rules. Conversely, an executing rule can access values in
the Database that have been placed there by other rules. The Database is commonly used for
"run-to-run" and "cross-application" balancing.
When creating Database variables, certain basic information must be provided such as the name of the
variable and its group, description, and number of generations.
Information represented by the variable is dynamic. Each generation of a variable may contain a different
value. Control-M/Analyzer tracks when each generation is created and which job or step created it.
Variables are assigned their values by:
 a DO SET or a DO EXTRACT specification in the rule definition
 manual update of the variable in the Variable Display screen
Control-M/Analyzer tracks and maintains all values (generations) of a variable from its creation, until the
number of values exceeds the maximum number of active generations (specified in the Database variable
definition). At this point, the oldest value of the variable is erased in order to store the newest value.
Control-M/Analyzer security mechanisms limit the users/jobs that can access Database variables.

35
Control-M/Analyzer User Guide

Database Variable Definition Screen


Database variable definition parameters are defined once using the Online facility. Formatted screens
guide the user through the definition process.
Although the Database variable definition is defined once, it can be updated by authorized users at any
time.
Figure 4 Database Variable Definition Screen
-------------------- Control-M/Anaylzer VARIABLE DEFINITION --------------------
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
NAME TOTAL GROUP INVENTORY
CREATED 04/04/00 - 10:10:10 BY M18 TYPE O (B-BATCH,O-ONLINR)
DESC TOTAL ITEMS IN INVENTORY FOR ALL PARTS
===========================================================================
MAXIMUM ACTIVE GENERATIONS 0032 GEN TYPE I (I-INDEPENDENT,H-HIERARCHICAL)
CURRENT ACTIVE GENERATIONS 0025
OLDEST -24 DATE 04/04/00
LATEST 0 DATE 08/08/00
===========================================================================
TYPE VAR
MASK

============= >>>>>>>>> BOTTOM OF VARIABLE DEFINITION <<<<<<<<<<< =============

PLEASE FILL IN VARIABLE DEFINITION 10.49.46

Defining Rule Parameters


Rules are data balancing tasks that contain all information necessary to analyze data and determine
whether data are balanced. The operations that rules can perform include: accessing variables in the
Database and other sources, performing calculations, searching and validating various data sources, and
processing actions as a result of the balancing task. All these operations are specified using the Rule
Definition screen.

36
Control-M/Analyzer User Guide

EXECUTE Block Structure Overview


The basic structure of an EXECUTE block is shown in Figure 5.
Figure 5 EXECUTE block basic structure
EXECUTE block name UPON execution criteria
ON data source
WHEN criteria
DO statement
DO statement
WHEN criteria
DO statement
DO statement

Each Control-M/Analyzer rule is composed of Basic Rule parameters, followed by a series of at least one
block (group) of statements. In Control-M/Analyzer, a block of statements beginning with EXECUTE is
called an EXECUTE block. These blocks are composed of data specifications, rule processing instructions,
and actions that are performed as a result of the rule.
Each EXECUTE block contains one ON statement, which determines the data source to be processed. The
EXECUTE block also contains at least one Automated Balancing statement (DO statement). Conditional
statements, repetitive processing statements, and branching statements determine how the EXECUTE
block is processed.
EXECUTE blocks are invoked sequentially within the rule. Certain blocks may be skipped at the time of
execution based on the resolution of their UPON criteria. Control-M/Analyzer also provides non-sequential
block processing capabilities, such as one block calling another block.
The structure of a sample rule and its EXECUTE blocks is illustrated in free format (not using the actual
syntax Control-M/Analyzer) in Table 10. Explanations of the abbreviations in the fourth column of
Table 10 are shown in Table 11.
For detailed descriptions of Balancing Rule Definition statements and parameters, see Rule Definition (on
page 348).
Table 10 Structure of Sample Control-M/Analyzer Rule

BASIC RULE RULE: Payroll BR


INFORMATION
OWNER: M99 BR

DESC: Compare the payroll totals of the current BR


month to those of last month, making sure that
a 10% deviation is not exceeded.

EXECUTE BLOCK #1 EXECUTE: Get Totals DSa

ON FILE: Payroll Reports DS

WHEN ‘TOTAL:’ Search for "Total:" in a specified Line/Column DI


Range

DO EXTRACT Total from current Payroll Reports DOa

37
Control-M/Analyzer User Guide

EXECUTE BLOCK #2 EXECUTE: Compare DS

ON DATA: Control-M/Analyzer Variables DI

DETERMINE Percentage deviation between the current total DI


and the previous one (obtained from the
Control-M/Analyzer Database)

IF Deviation is over 10% DI

DO SHOUT Send message to an operator DO

DO TERMINAT Terminate with user code of 0008 DO

ELSE Deviation is 10% or less DI

DO TERMINAT Do not send message DO


Terminate with user code of 0000

Table 11 Data identification parameters

Abbreviation Explanation

BR Basic rule parameter

DS Data selection statement

DI Data identification statement

DO DO statement

Rule Definition Screen


Rule Definition parameters are defined once using the Online facility. Formatted screens guide the user
through the definition process.
Rule Definition parameters are stored in libraries (partitioned data sets). For each rule, one member is
created containing basic rule information, balancing criteria, and balancing instructions.
Any number of libraries can be defined. For example, in an installation that employs distributed control,
each group of users can have its own library. This enables users to define data balancing rules without
any breach of security.
Although the rule is defined once, it can be updated by authorized users at any time.

38
Control-M/Analyzer User Guide

Figure 6 Rule Definition Screen


LIBRARY : CTB.PROD.RULES RULE : ADMSAL
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M18B GROUP ADMIN
UPDATED 06/07/99 - 15:30:05 BY M18B
DESC PRODUCE A SUMMARY SALARY REPORT FOR MANAGEMENT
OPTIONS
===========================================================================
EXECUTE INPUT UPON C
ON FILE FILENAME CTBT.PROD.EMPREP
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 001 - 060 COL 013 - 014 STOP AND/OR
STRING = EMP:
DO EXTRACT = NAME
LEVEL 0 LINE +000 COL +002 - +013 PROCESS TYP
DO EXTRACT = ID
LEVEL 0 LINE +000 COL +015 - +023 PROCESS TYP
DO EXTRACT = GROSS_SALARY
LEVEL 0 LINE +000 COL +080 - +090 PROCESS TYP
DO RULE = COMPNET ARG ID,GROSS_SALARY,NET_SALARY C
DO PRINT = %%NAME %%GROSS_SALARY %%NET_SALARY F C
DO
WHEN LINE - COL - STOP AND/OR
PLEASE FILL IN RULE DEFINITION. 12.52.47

Defining Balancing Mission Parameters


Detection of data-related processing errors and inconsistencies by Control-M/Analyzer is achieved by
specifying rules. The rule is the primary element in determining balancing procedures because it specifies:
 the location and type of input data that need to be balanced
 standards that determine if the input data are balanced
To arrive at a balancing decision, rules also provide extensive data manipulation techniques:
 the use of various functions that aid in data checking procedures
 the ability to store and access data items (variables) in the Control-M/Analyzer Database
Rules also specify different post-processing actions, such as the following:
 Add or remove conditions based on results of the balancing analysis.
 Send a message to the operator upon termination.
Rules can be scheduled by balancing missions, which determine scheduling based on calendar-related
processing cycles (daily, monthly, quarterly), and runtime prerequisite conditions (for example, invoke the
rule only if prerequisite condition OUTPUT_IS_READY exists).
A major advantage provided by missions is the ability to automatically invoke different rules
(meaning, different balancing checks and procedures) based on scheduling criteria. There is no need to
manually update job steps if, for example, a rule other than the daily rule should be run at end of month.
This is accomplished by creating different mission categories for each scheduling criteria.
Control-M/Analyzer Online Balancing Mission and Rule Definition screens allow specification of mission and
rule parameters. The rule name specified in the Mission Definition screen forms the link between the
mission and the rule. Balancing missions schedule one initial rule for execution, but the initial rule can
invoke an unlimited number of subsequent rules. As diagrammed in Figure 7, a balancing rule can be
scheduled by different missions (A).

39
Control-M/Analyzer User Guide

Figure 7 Online Balancing Mission and Rule Definition

Note: A rule can be invoked without being scheduled by a balancing mission. This is achieved by
specifying a rule name, instead of a mission name, as a parameter to the Control-M/Analyzer job step (B).
Also, one mission (see "Balancing Mission C" in diagram above) can schedule different rules at different
times (for example, daily processing versus month-end processing) using categories.
Basic summary and online screen information regarding both Mission Definition parameters and Rule
Definition parameters is provided in Online Facilities (on page 58). More information about Balancing
Mission Definition parameters is provided in Mission Definition Parameters (on page 527). More
information about Rule Definition parameters is provided in Rule Definition (on page 348).

Balancing Mission Definition Screen


Balancing Mission Definition parameters are defined once using the Online facility. A set of formatted
screens guides the user through the definition process.

40
Control-M/Analyzer User Guide

Figure 8 Balancing Mission Definition Screen


---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTRY --------(BM.S)
COMMAND ===> SCROLL===> CRSR
+------------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTRY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
==============================================================================
DAYS DCAL
AND/OR O
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
==============================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
==============================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< =======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

Balancing Mission Definition parameters are stored in libraries (partitioned data sets). For each mission,
one member is created containing one or more categories for that mission. For example, it is sometimes
necessary to invoke the rule differently on a regular day than at the end of the month. The balancing
mission contains scheduling instructions.
An unlimited number of libraries can be defined. For example, in an installation that employs distributed
control, each group of users can have its own library. This allows users to define data balancing missions
without any breach of security.
Although the balancing mission is defined once, it can be updated by authorized users at any time.

Invoking the Control-M/Analyzer Runtime Environment


General
The Control-M/Analyzer Runtime environment can be invoked by:
 A direct call to a rule
The rule is specified by either an application program, a job step, or another INCONTROL product.
The specified rule name is searched in the libraries referenced by the DABRULE DD statement. No
scheduling criteria are specified; the same rule is always activated. Both methods of rule activation
are discussed below.
 A balancing mission
A search is performed for the specified balancing mission name in the Active Balancing file. After
locating the appropriate mission, the rule specified by the mission is activated. When
Control-M/Analyzer is invoked using this method, scheduling criteria may be specified for
date-dependent balancing activities. For example, the same mission may activate different rules
based on the day of the week using different categories of the mission.

41
Control-M/Analyzer User Guide

Invoking Control-M/Analyzer Directly


Control-M/Analyzer can be invoked directly from one of the following:
Table 12 Direct Invocation Methods

Method Description

Application program The name of the rule to be invoked is specified by the call of the
application program to Control-M/Analyzer. For additional
information see C Calling Control-M/Analyzer User Routines (on
page 675).
Example:
Call CONTROLB(<rule name>)

Job step The rule to be invoked is specified by the JCL statement of the job
step (in the balancing job). This is the most frequently used
method.
Example:
// EXEC CONTROLB,RULE=rule,GROUP=group,
ARG='arg1,...,argn'

Note: The GROUP specification is mandatory only if the GROUP parameter in the rule
definition was omitted. Otherwise (meaning, the GROUP parameter was specified in the rule
definition), the GROUP specification is optional.
The ARG specification allows up to 50 arguments. See Passing Arguments While Invoking
Control-M/Analyzer (on page 42).

Another INCONTROL The rule to be invoked is specified by a DO CTBRULE statement in a


product Control-M job definition or a Control-D decollating definition.

When Control-M/Analyzer starts processing, it searches for the specified rule in the libraries referenced by
the DABRULE DD statement. If the rule is found, it is invoked. If the rule is not found, a runtime error
occurs.

Passing Arguments While Invoking Control-M/Analyzer


Arguments can be passed when directly invoking Control-M/Analyzer through the CONTROLB procedure
by specifying the following in the JCL statements of the job step:
// EXEC CONTROLB,RULE=rule,GROUP=group,MISSION=mission,ARG=arglist

42
Control-M/Analyzer User Guide

The variables in this statement are:


 rule – the name of the rule to be invoked
 group – the group name of the rule to be invoked
 mission – the mission name of the rule to be invoked
 arglist – the arguments to be passed to the rule, separated by commas
The arguments specified in arglist are stored in the RARGnn System variable. In this variable, nn is a 1- or
2-digit number that represents the position of the argument in arglist. To access the value of the first
argument in the list, specify RARG1.
Example
The following sample JCL and rule definition demonstrate how an argument can be passed when invoking
Control-M/Analyzer. In this case, the value PROD1.COPY.FILE1 is passed to Control-M/Analyzer as an
argument. In Control-M/Analyzer, this value is checked to indicate whether the data set exists at the site.
The JCL continues to run according to the result of the Control-M/Analyzer activation.
Figure 9 Argument Passing – Sample JCL
//CHKTAPE JOB ,TAPE,CLASS=A,MSGCLASS=X
//CTB EXEC CONTROLB,RULE=RULARG,ARG='PROD1.COPY.FILE1'
//COPYTAPE EXEC PGM=IEBCOPY,COND=(0,NE)
//SYSPRINT DD SYSOUT=*
//IN DD DSN=PROD.COPY.FILE1,DISP=SHR
//OUT DD DISP=(NEW,PASS),DSN=COPY.FILE1,
// VOL=(,RETAIN,,,SER=TAPE1899),UNIT=TAPE,
// LABEL=(1,SL)
//SYSIN DD *
C O=OUT,I=IN
//

Figure 10 Argument Passing – Sample Rule Definition


LIBRARY : CTB.PROD.RULES RULE : RULARG
OMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER USER5 GROUP PROD1
UPDATED 07/07/99 - 12:19:37 BY M42A
DESC
OPTIONS
===========================================================================
EXECUTE BLOCK1 UPON C
ON DATA
IF ISDSN('%%RARG01') C
DO TERMINAT = OK COD 0000
ELSE
DO PRINT = FILE %%RARG01 DOES NOT EXIST F C
DO TERMINAT = NOTOK COD 0008
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====
PLEASE FILL IN RULE DEFINITION. 13.25.00

43
Control-M/Analyzer User Guide

Invoking Control-M/Analyzer With Balancing Missions


Balancing missions can invoke Control-M/Analyzer from one of the following:
Table 13 Balancing Mission Invocations

Method Description

Application program The name of the mission to invoke is specified by a program call to
Control-M/Analyzer in the application program. For additional
information see Appendix C, "Calling Control-M/Analyzer User
Routines,".
Example:
CALL CONTROLB(<mission>,...);

Job step The name of the mission to be invoked is specified in the JCL
statements of the job step (which invokes the Control-M/Analyzer
Runtime Environment).
Example:
// EXEC CONTROLB,MISSION=msn,GROUP=group,
ARG='arg1,...,argn'

Note: The GROUP specification is mandatory only if the GROUP parameter in the rule definition was
omitted. Otherwise (the GROUP parameter was specified in the rule definition), the GROUP specification is
optional. The ARG specification allows up to 50 arguments. For more information, see Passing Arguments
While Invoking Control-M/Analyzer (on page 42).
When the call or step that invokes Control-M/Analyzer is executed, Control-M/Analyzer first checks each
entry in the Active Balancing file to locate the appropriate balancing mission. The Active Balancing file
search method consists of the phases shown in Table 14.
Table 14 Active Balancing Search Phases

Phase Description

Phase 1 All mission entries with corresponding mission names are checked to
see if their runtime scheduling criteria are met. Missions whose
runtime scheduling criteria are met advance to the second phase for
further checking.

Phase 2 Missions that have passed the first phase are checked to see if the
values specified by the JOB and STEP parameters match the job
name and (optional) step name of the current call or step.
Note: The * mask character can be specified at the end of JOB and
STEP names.

The SCOPE parameter of each eligible mission entry in the Active Balancing file is checked to determine a
JOB/STEP match. The SCOPE parameter specifies one of the options shown in Table 15.

44
Control-M/Analyzer User Guide

Table 15 SCOPE Parameter Options

Option Description

SINGLE If JOB and STEP values match, the mission entry is eligible for
further checking only if it has not been invoked before. The SINGLE
option guarantees that this mission entry is only invoked once, by a
single Control-M/Analyzer invocation.

STEP If JOB and STEP values match, the mission entry is eligible for
further checking if it has not been invoked before, or it was
previously invoked by the current STEP in the current JOB. The
STEP option enables the mission entry to be invoked repeatedly,
provided that the mission entry is invoked from the same job step
each time, for example, from an application program that invokes
Control-M/Analyzer from within a loop.

JOB If the JOB value matches, the mission entry is eligible for further
checking if it has not been invoked before, or it was previously
invoked by the current JOB. The JOB option enables the mission
entry to be invoked by several Control-M/Analyzer invocations,
provided that the invocations all originated from the same job.

ALL The mission entry is always eligible for further checking. The ALL
option enables the mission entry to be invoked regardless of the
JOB and STEP that previously invoked the mission entry.

The first mission that matches the above criteria is selected for execution.
If no matching mission is found, a runtime error occurs.

45
Control-M/Analyzer User Guide

Control-M/Analyzer Components
The main components of Control-M/Analyzer and their interrelationships are discussed in this section. The
described components include
 Runtime environment (1)
 Rule Definition library (2)
 Mission Definition library (3)
 Repository (4)
 Online Definition, Tracking, and Control facility (5)
 New Day procedure (6)
 Reporting facility (7)
 Utilities (8)
Figure 11 Control-M/Analyzer Main Components

46
Control-M/Analyzer User Guide

Overview
The heart of the Control-M/Analyzer balancing system is the Control-M/Analyzer Runtime environment
(1). The Runtime environment is usually activated by a job step, a subroutine call from an application
program, or a call to Control-M/Analyzer from another INCONTROL product.
The Runtime environment is responsible for the execution of balancing procedures (known as rules and
balancing missions). Rules contain user-defined instructions for balancing and are stored in the Rule
Definition library (2). Missions contain rule scheduling criteria and are stored in the Mission Definition
library (3). Both these libraries are standard partitioned data sets and are user-defined.
When the Runtime environment is activated, the name of the mission or rule that should be invoked is
specified. The Runtime environment then performs the balancing procedures specified by the mission or
rule.
The Repository (4) is accessed by all the components of Control-M/Analyzer. Every action performed by
Control-M/Analyzer is recorded in the Repository. The Repository can be scanned and updated using the
Online Tracking and Control facility (5), which is a full screen, user-friendly interface that can be activated
under TSO, TSO/ISPF, ROSCOE/ETSO, CICS, VTAM, IMS/DC, IDMS/DC, or COMPLETE.
The New Day procedure (6) analyzes the mission scheduling parameters and places missions to be
invoked in the Active Balancing file on a daily basis.
The Reporting facility (7) accesses the Repository to produce various reports that are required in an active
data center.
Control-M/Analyzer Utilities (8) enhance the operation of Control-M/Analyzer by facilitating maintenance,
backup and archiving of the Repository, and by performing other necessary functions. For detailed
information about Control-M/Analyzer utilities, see the INCONTROL for z/OS Utilities Guide.

Repository
The Repository and the IOA Core consist of the files shown in Table 16.
Table 16 IOA Core and Repository Files

Control-M/Analyzer Repository  Active Balancing file


 Database
 Rule Activity file
 Reports file

IOA Core  IOA Conditions file


 Log file
 Manual Conditions file

The Repository is accessed by all components of Control-M/Analyzer: New Day procedure, Online Tracking
and Control facility, Utilities, and Reporting facility. Multiuser access is synchronized and safely controlled.

47
Control-M/Analyzer User Guide

Active Balancing File


The Active Balancing file contains entries for all missions that have executed recently, or are likely to be
executed in the near future. It is a control file used by operations personnel to query and update the
status of the various balancing tasks.

Control-M/Analyzer Database
The Control-M/Analyzer Database contains information about each Control-M/Analyzer Database variable.
The Database tracks the generations (previous and current values) of each variable. Database variables
are grouped according to logical divisions in the workplace.

Rule Activity File


The Rule Activity file contains historical information about balancing activity (and rollbacks) within jobs.
This information is accumulated for every Control-M/Analyzer invocation. The information includes: names
of variables that have been committed, reference to summary reports generated, balancing results, and
rollback information.

Reports File
The Reports file contains the summary report of each invocation of a Control-M/Analyzer rule. It can be
accessed through the Rule Activity file. The Report Viewing screen (option R) displays messages that
appeared during each invocation listed in the Rule Activity display (Screen BA).

IOA Conditions File


The IOA Conditions file contains lists of all existing prerequisite conditions under the control of
Control-M/Analyzer.
Note: Prior to version 6.0.00 a single file, the IOA Conditions/Resources File, contained all IOA
prerequisite conditions and all Control and Quantitative resources. As of version 6.0.00, the IOA
Conditions/Resources File has been replaced by two files:
 the IOA Conditions file, which contains all IOA prerequisite conditions
 the Control-M Resources file, which contains all Control and Quantitative resources

IOA Log File


The IOA Log file contains a complete audit trail of every event under the Control-M/Analyzer balancing
environment. Control-M/Analyzer logs every item of meaningful information about its operation.

IOA Manual Conditions File


The IOA Manual Conditions file contains a list of all prerequisite conditions that are expected to be added
manually by the Control-M/Analyzer user, for example, OUTPUT-OK, AR-BALANCED.

48
Control-M/Analyzer User Guide

Mission and Rule Definition Libraries


Missions and rules are defined as regular members in libraries (partitioned data sets). Usually a different
library is allocated to:
 balancing missions
 rules
An unlimited number of libraries can be used (for example, due to security considerations). More
information about defining missions, rules, and the New Day procedure is provided later in this chapter.

Online Definition, Tracking, and Control Facility


Users of Control-M/Analyzer communicate with the system through the Online Definition, Tracking, and
Control facility, a set of integrated, interactive "fill-in-the-blank" screens that provide access to
Control-M/Analyzer information. Its operation is characterized by:
 uniform ISPF-like screen handling conventions
 menu-driven functions
 dynamic PFKey assignment
 "All information on the screen" approach
 management of many screens concurrently (including TSO applications)
The Online facility provides access to the Repository and the IOA Core. It enables the user to see and
update the following:
 Database Variable Definition parameters
 Rule Definition parameters
 Mission Definition parameters
 the status of active missions
 historical data about Control-M/Analyzer operations
 the status of prerequisite conditions under supervision of Control-M/Analyzer
 the IOA Log file
 calendars
The Online Definition, Tracking, and Control facility can be activated under the environments shown in
Table 17, regardless of whether the Control-M/Analyzer Runtime environment is active.

49
Control-M/Analyzer User Guide

Table 17 Environments for Facility Activation

TSO (native) VTAM

TSO/ISPF IMS/DC

ROSCOE/ETSO IDMS/DC

CICS COM-PLETE

TSO users can activate other online application programs (including ISPF) parallel to the Online facility
under the multiplication environment created by Control-M/Analyzer.
Control-M/Analyzer provides full color support when activated from a screen with extended 7-color
support.

New Day Procedure


The New Day procedure is the primary mechanism used to issue (activate) new missions for
Control-M/Analyzer.
The New Day procedure is activated to determine which missions may potentially be activated on a
specific date. Eligible missions are placed in the Active Balancing file. A balancing mission may not
necessarily be invoked. A balancing mission is not invoked if a job on which it depends is never run.
Each time the Control-M/Analyzer Runtime environment is invoked from a job step, Control-M/Analyzer
reads the missions from the Active Balancing file and determines which mission to invoke.
The New Day procedure can be activated automatically by a scheduler at a predefined time each day. The
New Day procedure can also be activated manually by submitting a job.

50
Control-M/Analyzer User Guide

Figure 12 New Day Procedure

Reporting Facility
The following types of reports are available:
 reports produced automatically by the operation of Control-M/Analyzer
 reports produced using the IOA KeyStroke Language
 Control-M/Analyzer special purpose reports
Some Control-M/Analyzer reports are produced from information in the Rule Activity file, Report file, or
IOA Log file. Other reports are produced from the Active Balancing file, mission definition files, and the
Database.
The Reporting facility can be activated at any time. Sample reports are provided in the IOA SAMPLE
library. The Reporting facility is described in Report Generation (on page 625).

51
Control-M/Analyzer User Guide

Utilities
Maintenance, backup and archiving of the Database and other Control-M/Analyzer files can be performed
using Control-M/Analyzer and IOA utilities. Utilities provide greater overall flexibility in the balancing
process. For information about utilities see the INCONTROL for z/OS Utilities Guide.
Typical utility functions include:
 deleting unneeded entries from Repository files
 recreating Control-M/Analyzer index files
 checking the integrity of Control-M/Analyzer files
 printing special reports
 formatting and maintaining Control-M/Analyzer data and index files

IOA Environment
Control-M/Analyzer can work in conjunction with other INCONTROL products in the Integrated Operations
Architecture (IOA) environment. All INCONTROL products use the same data for scheduling, control, and
audit trail information.
The following features, which have already been discussed in relation to Control-M/Analyzer, are
standardized across the INCONTROL family of products:
 IOA Conditions files
 Log file
 Manual Conditions file
 Calendars
 Online facility
 AutoEdit facility
 Reporting facilities
The integration between Control-M/Analyzer and other INCONTROL products involves more than just data
sharing by using the same IOA Core and AutoEdit facility. It involves many aspects of unified scheduling
and control and a common user interface, examples of which can be found throughout this guide.
Control-M and Control-D can invoke Control-M/Analyzer directly, and information can be returned to
Control-M and Control-D after rule termination. These interfaces greatly enhance integration in the IOA
environment. For additional information see Control-M/Analyzer Interfaces (on page 632).

Prerequisite Condition Concept


The prerequisite condition is one of the fundamentals concepts of the Control-M/Analyzer balancing and
IOA production environment.

52
Control-M/Analyzer User Guide

A prerequisite condition is a user-defined descriptive name given to a situation, event, or condition. The
data of a job is balanced (checked, verified, examined) only when all prerequisite conditions defined as
necessary for the execution of the rule exist. Prerequisite conditions are either created by previous jobs
(for example, by Control-M, by Control-D missions, by Control-O rules, and by Control-M/Analyzer
missions and rules), or created manually using the Online Tracking and Control facility.
Figure 13 Prerequisite Conditions

Examples of prerequisite conditions are shown in Table 18.

53
Control-M/Analyzer User Guide

Table 18 Prerequisite Condition Examples

Condition Description

BALANCING-OK an event

TOTALS-IN-TOL an event

BALANCE-CHECKED completion of a manual operation

EJ18FOR-FINISHED-OK an event

PRINTING-ALLOWED an ongoing situation

DATA-SET-CREATED creation of a data set

IMS-ACTIVE an ongoing situation

A list of prerequisite conditions can be specified in the mission definition parameters. Control-M/Analyzer
allows mission execution only if all prerequisite conditions exist.
Prerequisite conditions can be used to create any kind of dependency (for example, mission to mission,
mission to job, manual operations, creation of a data set).
Prerequisite conditions can be added or deleted in the following ways:
 specification of statement DO COND in a Control-M/Analyzer rule
 use of the Online Tracking and Control facility
 through an application program or a job step using a supplied routine or utility
The Online Tracking and Control facility adds conditions like AR-BALANCED or PRINT-SALARY. These
prerequisite conditions represent manual operations. They can be added by any authorized user.
The most common way of adding or deleting a condition is by defining it in rule definition parameters.
Prerequisite conditions are strictly under the user’s control. An unlimited number of conditions, and
therefore an unlimited number of dependencies, can be created. Prerequisite conditions can be used for
any purpose.

IOA Calendar Facility


Specification of scheduling criteria for missions can be simplified by using calendars. A calendar is a
defined schedule (for example, every day except Saturdays and Sundays of each month) that can be
applied to missions.
Calendars are defined in the IOA Calendar facility. Each calendar is given a unique name that can be
specified in mission definitions. A particular calendar (meaning, a unique set of dates) only needs to be
defined once.
Specifying the name of a calendar in a mission definition enables that mission to be scheduled on the
dates specified in that calendar.
Two types of calendars can be defined: Regular and periodic.

54
Control-M/Analyzer User Guide

Regular calendars consist of scheduling dates or days (of the week) that can be defined according to
monthly patterns.
Calendar Examples
Table 19 Regular Calendar Examples

WEEKDAYS Schedules rules each Monday through Friday in each month.

WEEKENDS Schedules rules each Saturday and Sunday in each month.

QUARTERLY Schedules rules on the last day of each quarter: March 31, June 30,
Sept. 30, Dec. 31.

Regular calendars are especially useful when many missions have the same schedule. Defining that
schedule once in a calendar, and specifying the name of that calendar in the mission definition of those
missions, makes it unnecessary to individually define that schedule in the mission definition of those
missions.
Periodic calendars are especially useful when scheduling dates do not conform to fixed date/day of the
week/month patterns.
Example
PAYCAL – Schedules missions (for example, payroll) every other Wednesday. Scheduling occurs on the
first, third, and (if there is one) fifth Wednesday of some months. Scheduling occurs on the second and
fourth Wednesday of other months.
The IOA Calendar facility is described in further detail in IOA Calendar Facility (on page 204).

Date Definition Concepts


IOA uses the following types of date definitions:
 system date
 working date
 original scheduling date

System Date
This date is supplied by the operating system. It should be the actual calendar date starting and ending at
midnight.

Working Date
Many sites do not use midnight as the formal time for changing to a new date. For example, the working
date can start at 6:00 A.M. every morning. The hours between midnight and 6:00 A.M. would therefore
belong to the previous system date.

55
Control-M/Analyzer User Guide

The working date, meaning, the time at which a date changes at the site, is defined in the
Control-M/Analyzer installation parameters. New date processing generally begins at the start of the new
working date.

Original Scheduling Date


The original scheduling date (ODATE) is the working date that Control-M/Analyzer assigns to missions,
messages or conditions.
Every item under Control-M/Analyzer is assigned an original scheduling date. For missions, it is the date
on which the mission should be scheduled for execution. For messages, it is the original scheduling date
of the mission that generated the message.
A mission is always associated with an original scheduling date. For example, a mission with an original
scheduling date of February 1 can be invoked on system date February 3 when the working date is
February 2.

Date Standards and Date Field Formats


Date standards and date field formats use either Gregorian or Julian dates.

Gregorian Dates
Gregorian dates are indicated in the guide by the following symbols.
Table 20 Gregorian Date Formats

Symbol Description

dd Day of the month (01-31)

mm Month (01-12)

yy Year. Last two digits of the year


Note: If the last two digits in the specified year are a number less
than 56, INCONTROL presumes that the year is in the 21st century
(for example, if yy=15, the year 2015 would be presumed).
Otherwise, INCONTROL presumes that the year is in the 20th
century (for example, if yy=80, the year 1980 would be
presumed).

yyyy Year. 4-digit year

Whether a field holds a 4-character date (month and day), a 6-character date (month, day and 2-digit
year) or an 8-character date (month, day and 4-digit year) depends on the field. However, the format of
the 4-character, 6-character or 8-character date depends on the date standard defined at installation.
INCONTROL products support three date standards for Gregorian dates. Each standard has an 8-character
format, a 6-character format, and a 4-character format. Only one Gregorian date standard is defined at
any site.

56
Control-M/Analyzer User Guide

These supported Gregorian date standards are described in Table 21.


Table 21 Gregorian Date Standards

Standard 4-Character Date 6-Character Date 8-Character Date

MDY mmdd mmddyy mmddyyyy

DMY ddmm ddmmyy ddmmyyyy

YMD mmdd yymmdd yyyymmdd

Julian Dates
Julian dates (also supported by INCONTROL products) are indicated in the guide by the symbols shown in
Table 22.
Table 22 Julian Date Formats

Symbol Description

jjj or ddd Day of the year (001 - 365 or 366, as appropriate for the year)

yy Last two digits of the year

yyyy 4-digit year

Julian date fields have either three, five, or seven characters. Whether a Julian date field holds a
3-character date (day of year only), 5-character date (day of year and 2-digit year) or a 7-character date
(day of year and 4-digit year) depends on the field definition. However, the format of the date depends
on the installation-defined date standard.
For example, the Julian date for the calendar date of 28 February 2000 would be represented in jjj or ddd
format as 059, in yyjjj or yyddd format as 00059, and in yyyyjjj or yyyyddd format as 2000059.

57
2
2
Online Facilities
 Overview (on page 58)
 IOA Features (on page 59)
 Database Variable Definition Facility (on page 86)
 Rule Definition Facility (on page 107)
 Balancing Mission Definition Facility (on page 124)
 Balancing Status Facility (on page 145)
 Rule Activity Display Facility (on page 157)
 Condition and Resource Handling Facility (on page 180)
 IOA Log Facility (on page 195)
 IOA Calendar Facility (on page 204)
 Utilities Under ISPF (on page 219)

Overview
The Online facility is the basic means of communication between the user and Control-M/Analyzer.
Online mission and rule definition gives users the ability to define and modify balancing missions, rule
parameters, and database variables in the Control-M/Analyzer environment.
Online tracking displays the current status of all parameters relating to a specific balancing mission or
rule, a group of balancing missions, or all the balancing missions, scheduled under Control-M/Analyzer.
Control-M/Analyzer also enables the user to view current and past values of Database variables and rule
statuses. Control-M/Analyzer rule invocations are tracked as well.
Online control allows authorized users to modify all parameters relating to a specific mission or rule, a
group of missions or rules, or all the missions and rules scheduled under Control-M/Analyzer, as well as
Database variables.
The following pages describe the main features available under the Online facility.

58
Control-M/Analyzer User Guide

IOA Features
This section discusses the IOA features common to all INCONTROL products.

General IOA Features


General IOA features include:
 Customization
 Environment Support
 Terminal Support
 Special Character Usage on Terminals
 Color Support
 Prefixing
 Character Masking

Customization
IOA screens, constants, messages, colors, commands, and PFKey definitions can be site-modified to adapt
them to local needs.
INCONTROL products can be customized globally, that is, for the whole site, using the INCONTROL
Installation and Customization Engine (ICE), according to profile variables defined during installation.
In addition, INCONTROL products can be customized to respond differently to individual users if these
profile variables are specified in user profile members.
For example, depending on the setting of a variable in a particular user profile member, upon exit from a
screen in which changes have been requested, this INCONTROL product may either perform the
requested changes automatically or display a confirmation window before performing the changes.
Customization issues are discussed in the INCONTROL for z/OS Installation Guide.
Note: Due to customization, the screens and examples illustrated in this guide may differ from the ones
used at your site.

59
Control-M/Analyzer User Guide

Environment Support
The Online facility can be activated under the following environments:
 TSO (native)
 TSO/ISPF
 ROSCOE/ETSO
 CICS
 VTAM
 IMS/DC
 IDMS/DC
 COM-PLETE
Cross memory interfaces (to the Online monitor) are optional under native TSO, TSO/ISPF, and
ROSCOE/ETSO. They are always used under the other environments.
There are slight differences in the operation of the Online facility under the different environments.
Special notes are provided in this guide where applicable.

Terminal Support
IOA supports the following models of IBM 3270 terminals:
 Model 2 – 24 lines, 80 columns
 Model 4 – 43 lines, 80 columns
 Model 3 – 32 lines, 80 columns
 Model 5 – 27 lines, 132 columns
Note: When using the IOA online facility under IMS/DC and IDMS/DC, all model types display 24 lines and
80 columns.
IOA adjusts to the screen size in order to use the maximum available data area on the screen.

Special Character Usage on Terminals


In certain cases, special keyboard characters, such as $, #, and @, are assigned special meanings. The
characters specified appear on standard American terminals but may not be available on other keyboards.
In addition, some special characters on your keyboard may be assigned different hexadecimal values than
the ones recognized by IOA. Special keyboard mapping requirements, and a complete discussion of the
conventions used in this guide, are described in Conventions Used in this Guide (on page 14).

60
Control-M/Analyzer User Guide

Color Support
When INCONTROL products are activated from a screen with extended seven-color support, they make
extensive use of the color attributes of the screen. The concept of management by color is emphasized in
INCONTROL screens.
Like all screen attributes, the color attribute for each field is defined externally to the program and can be
locally modified by the site.
Note:
 IOA does not automatically recognize IMS/DC and IDMS/DC terminals as supporting extended color
attributes. If your IMS/DC or IDMS/DC terminal supports extended color attributes and you want IOA
to recognize this, refer to the INCONTROL z/OS Administrator Guide for more information.
 At this time, IOA does not support extended color attributes under COM-PLETE.
 Due to ISPF characteristics, color changes cannot occur in adjacent columns but must be separated
by an attribute byte without color, that is, black. Therefore, some IOA screens have a different
appearance under ISPF than under other online environments, such as native TSO and CICS.

Prefixing
For fields that automatically support prefixing, selection strings are always treated as prefixes. Selection is
made if a segment of the text beginning with the first letter, that is, any prefix, matches the selection
criterion.
Examples
Assume the following names exist: A3, A4, M, M01, M03, M12, M13, M22, M23, M30, M33, M103, M135,
M301.
Table 23 Prefixing Examples

Entry Matching Value

blank All of the above values

A A3, A4

M M, M01, M03, M12, M13, M22, M23, M30, M33, M103, M135, M301

M1 M12, M13, M103, M135

M13 M13, M135

If a field supports prefixing, this fact is indicated in its description.

61
Control-M/Analyzer User Guide

Character Masking
For fields that support masking, mask characters function as follows:
 * represents any number of characters, including no characters
 ? represents any one character
For fields that do not automatically support prefixing, a prefix value can be specified by ending the
selection string with an asterisk.
Examples
Assume the following names exist: A3, M, M3, M01, M03, M13, M23, M33, M103, M435, M2243.
Table 24 Masking Examples

Entry Matching values

* All the above values

M?3 M03, M13, M23, M33

M?3* M03, M13, M23, M33, M435

M??3 M103

M*3 M3, M03, M13, M23, M33, M103, M2243

M* M, M3, M01, M03, M13, M23, M33, M103, M435, M2243


Since the last character in this example is *, M is treated as a prefix.

If a field supports masking, this fact is indicated in its description.

62
Control-M/Analyzer User Guide

IOA Entry Panel


Enter the IOA Online facility according to the instructions of your INCONTROL administrator. Upon
entering the IOA Online facility, the IOA entry panel may be displayed.
Note: Display of the IOA Entry Panel is optional. If your INCONTROL administrator determined that the
entry panel is bypassed, the IOA Primary Option menu, which is discussed in the following section, is
displayed.
Figure 14 IOA Entry Panel
--------------------------- IOA ENTRY PANEL -------------------------------

+-----------------------------------------------------------+
| |
| USER ID ===> |
| |
| PASSWORD ===> |
| |
| NEW PASSWORD ===> ===> |
| |
+-----------------------------------------------------------+

PLEASE FILL IN USER ID AND PASSWORD AND PRESS ENTER 18.30.18

Type your user ID and password and press Enter. If you enter a correct user ID and password, the IOA
Primary Option menu is displayed.
The IOA Online facility allows three attempts to enter a valid user ID and password combination. After the
third unsuccessful attempt, the program is terminated.
To change a password, type the new password twice, once in the NEW PASSWORD field and once in the
confirmation field.

63
Control-M/Analyzer User Guide

IOA Primary Option Menu


The IOA Primary Option menu is the primary interface to functions available under the various
INCONTROL products. The options displayed in the menu depend on the INCONTROL products installed
at the site, and the functions and facilities that have been authorized to you.
If only Control-M/Analyzer is installed at your site and you are authorized to access all functions and
facilities, the screen illustrated in Figure 15 is displayed:
Note: When the Online facility is activated as an ISPF application, Option 6 is displayed as: "6 UTILITIES
Online Utilities." In this case, Option 6 activates the Online Utilities under ISPF. When the Online facility is
not activated under TSO or TSO/ISPF, Option 6 is inactive.
Figure 15 IOA Primary Option Menu where only Control-M/Analyzer is Installed
--------------------- IOA PRIMARY OPTION MENU ------------------(1)
OPTION ===> USER N22A
DATE 19.08.01

4 COND-RES IOA Conditions/Resources Display


5 LOG IOA Log Display
6 TSO Enter TSO Command
7 MANUAL COND IOA Manual Conditions Display
8 CALENDAR DEF IOA Calendar Definition
IV VARIABLE DATABASE IOA Variable Database Definition Facility
C CMEM DEFINITION CTM Event Manager Rule Definition
BB BALANCING STATUS CTB Bal Mission Status Display
BM MISSION DEF CTB Balancing Mission Definition
BV DB VARIABLE DEF CTB Database Variable Definition
BR RULE DEFINITION CTB Rule Definition
BA RULE ACTIVITY CTB Rule Status Display

COMMANDS: X - EXIT, HELP, INFO OR CHOOSE A MENU OPTION 18.04.07

To select an option, type the option number or letters in the OPTION field and press Enter. Alternatively,
for a number option, press the PFKey of the same number. For example, to select the LOG option, press
PF05/PF17.
Note: Your INCONTROL administrator can limit the options displayed on a user-by-user basis and can
alter option numbers and customize option descriptions. Product supplied options are discussed in this
guide.
Certain IOA commands, functions, and facilities (options) are shared by all INCONTROL products. These
shared IOA commands, functions and facilities are described later in this chapter, and outlined in
Table 25.

64
Control-M/Analyzer User Guide

Table 25 INCONTROL Shared IOA Functions and Facilities

Option Function Description

4 COND/RES Display and update the contents of the IOA Conditions


file and the Control-M Resources file.

5 LOG View audit trail information about jobs, missions, and


rules scheduled under the supervision of INCONTROL
products.

6 TSO Perform TSO commands.

Note: When the Online facility is activated as an ISPF application, Option 6 is


displayed as: "6 UTILITIES Online Utilities." In this case, Option 6 activates the
Online utilities under ISPF. When the Online facility is not activated under TSO
or TSO/ISPF, Option 6 is inactive.

7 MANUAL COND Display a list of prerequisite conditions that should be


confirmed manually by operations personnel.

8 CALENDAR DEF Define scheduling calendars.

X EXIT Exit the Online facility

INFO INFO Display a window in the IOA Primary Option Menu. The
window contains information about installed
INCONTROL products. For more details on the
information displayed by this command, see IOA
Version Information (on page 69).

Note: Entering =1 in the command line of any other screen returns you to the IOA Primary Option Menu
that is displayed at your site.
These shared functions and facilities are described in further detail in this chapter.
The functions and facilities (options) described in Table 26 are applicable to Control-M/Analyzer.

65
Control-M/Analyzer User Guide

Table 26 Control-M/Analyzer Functions and Facilities

Option Function Description

BB BALANCING STATUS Display and update the status of active balancing


missions.

BM MISSION DEF Define balancing missions.

BV DB VARIABLE DEF Define, display, and update Database variables.

BR RULE DEFINITION Define balancing rules.

BA RULE ACTIVITY Display rule activity and results of invoking


Control-M/Analyzer rules.

The IOA Primary Option menu illustrated in Figure 16 is displayed at sites supporting all currently
available INCONTROL products (under ISPF).
Note: Option OK (KOA Recorder facility) is available only under IOATSO, and not under IOAISPF or
IOAMON.
Figure 16 IOA Primary Option Menu when all INCONTROL Products are Installed
--------------------- IOA PRIMARY OPTION MENU ------------------(1)
OPTION ===> USER N06

IOA CONTROL-D/V CONTROL-O

4 COND-RES A MISSION STATUS OR RULE DEFINITION


5 LOG M MISSION DEF OM MSG STATISTICS
6 TSO R REPORT DEF OS RULE STATUS
7 MANUAL COND T RECIPIENT TREE OL AUTOMATION LOG
8 CALENDAR DEF U USER REPORTS OA AUTOMATION OPTS
IV VARIABLE DATABASE F PC PACKET STATUS OC COSMOS STATUS
DO OBJECTS OK KOA RECORDER

CONTROL-M & CTM/Restart CONTROL-M/Analyzer CONTROL-M/Tape


2 JOB SCHEDULE DEF BB BALANCING STATUS TR RULE DEFINITION
3 ACTIVE ENV. BM MISSION DEF TP POOL DEFINITION
C CMEM DEFINITION BV DB VARIABLE DEF TV VAULT DEFINITION
BR RULE DEFINITION TI INQ/UPD MEDIA DB
BA RULE ACTIVITY TC CHECK IN EXT VOL

COMMANDS: X - EXIT, HELP, INFO OR CHOOSE A MENU OPTION 16.20.21

Note: Entering =1 in the command line of any other screen returns you to the IOA Primary Option Menu
that is displayed at your site.
For a description of the options for other INCONTROL products, see the user guides of the respective
products.
Additional options available on the IOA Primary Option menu when operating Control-M/Analyzer with
other INCONTROL products are listed in Table 27.

66
Control-M/Analyzer User Guide

Table 27 IOA Primary Option Menu Options

Option Name Description

IV VARIABLE DATABASE Define, display and update IOA Database


variables used by Control-O and
Control-M.

Note: Option IV is available only at sites where Control-O or CMEM are installed.

2 JOB SCHEDULE DEF Define or modify job production


parameters.

3 JOB STATUS Display and update status of jobs


scheduled under Control-M.

C CMEM DEFINITION Define or modify CMEM rules.

Note: Options 2, 3, and C are available only at sites where Control-M is installed.

A MISSION STATUS Display and update active missions status.

M MISSION DEF Define migration, printing, backup, and


restore missions.

R REPORT DEF Define decollating missions (including


indexing).

T RECIPIENT TREE Display and update the Recipient Tree.

U USER REPORTS Display and update the status of user


reports. View reports online.

F PC PACKET STATUS Display the status of reports (packets)


scheduled for transfer from the mainframe
to a PC.

DO OBJECTS Manage Control-D objects.

Note: Options A, M, R, T, U, F, and DO are available only at sites where Control-D or


Control-V are installed.

67
Control-M/Analyzer User Guide

Option Name Description

OR RULE DEFINITION Define rules.

OM MSG STATISTICS View message statistics.

OS RULE STATUS View Rule Status screen.

OL AUTOMATION LOG Display commands, messages and/or


traces.

OA AUTOMATION OPTS Display available operator productivity


tools.

OC COSMOS STATUS Display or modify the status of


Control-O/COSMOS-controlled objects and
databases.

OK KOA RECORDER Record VTAM scripts.

Note: Options OR, OM, OS, OL, OA, OV, OC, and OK are available only at sites where
Control-O is installed.

TR RULE DEFINITION Define rules.

TP POOL DEFINITION Define pools.

TV VAULT DEFINITION Define vaults.

TI INQ/UPD MEDIA DB Display the Inquire/Update screen.

TC CHECK IN EXT VOL Check in external volumes.

Note: Options TR, TP, TV, TI, and TC are available only at sites where Control-M/Tape is
installed.

68
Control-M/Analyzer User Guide

IOA Version Information


Enter INFO (or I) in the OPTION field of the IOA Primary Option menu to display the IOA Version
Information window, as illustrated in Figure 17. This window lists the version and level of each
INCONTROL product installed at the site, plus the CPU ID and current system date. The IOA Version
Information window also identifies the unique IOA QNAME assigned to the site. For further information
about the IOA QNAME, see the IOA operational parameters step, the IOAPLEX parameters step, and the
adding IOA structures to the CFRM step, all in the INCONTROL for z/OS Installation Guide. Press Enter or
END (PF03/PF15) to exit the window and return to the IOA Primary Option menu.
Figure 17 IOA Version Information
--------------------- IOA PRIMARY OPTION MENU ------------------(1)
OPTION ===> USER N06

IOA CONTROL-D/V CONTROL-O


+----------------------------------------------+
4 COND-RES | IOA VERSION INFORMATION | EFINITION
5 LOG | | ATISTICS
6 TSO | IOA Version 6.1.00 | TATUS
7 MANUAL CON | IOAGATE Version 6.1.00 | TION LOG
8 CALENDAR D | CONTROL-M Version 6.1.00 | TION OPTS
IV VARIABLE D | CONTROL-M/RESTART Version 6.1.00 | STATUS
| CONTROL-M/ANALYZER Version 6.1.00 | CORDER
| CONTROL-M/TAPE Version 6.1.00 |
| CONTROL-D Version 6.1.00 |
CONTROL-M & CTM | CONTROL-V Version 6.1.00 | ape
| CONTROL-O Version 6.1.00 |
2 JOB SCHEDU | | EFINITION
3 ACTIVE ENV | | EFINITION
C CMEM DEFIN | DATE 19.08.01 CPUID 02078D 7060 | DEFINITION
| IOA QNAME IOAR610 | D MEDIA DB
| | IN EXT VOL
+----------------------------------------------+

COMMANDS: X - EXIT, HELP, INFO OR CHOOSE A MENU OPTION 17.00.29

Multi-Screen Control
It is not necessary to return to the IOA Primary Option menu to move from one online facility to another.
To speed up transfer of control between screens of different facilities and to enable you to manage
several online facilities at the same time, transfer control commands can be specified. Transfer commands
take you directly from your current screen to the requested screen. Transfer commands can be used to
reach any screen that can be accessed by the IOA Primary Option menu at your site.
Each transfer control command consists of an equal sign immediately followed by one of the options of
the IOA Primary Option menu, which represents the target screen of the transfer. For example, from any
screen, enter:

69
Control-M/Analyzer User Guide

Table 28 IOA Transfer Control Commands

Command Description

=5 to access the IOA Log screen.

=4 to access the IOA Conditions/Resources screen.

=BB to access the Control-M/Analyzer Balancing Status screen.

=1 to access the IOA Primary Option menu.

If you use a transfer command to reach another screen, the state of the current screen remains
unchanged when you return to it using another transfer command.
The INCONTROL administrator can globally deactivate any or all of the transfer commands.

Fast Exit from the IOA Online Facility


To exit immediately from the IOA Online facility, type =X on the command line and press Enter.
In most cases, the =X command has the same effect as pressing END (PF03/PF15) in all open screens
and then entering X (Exit) in the IOA Primary Option menu. Any window, such as the Exit Option window,
that would be displayed when exiting an open screen is displayed when the =X command is entered.
However, when the =X command is entered while definition screens such as the Calendar Definition
screen are open, changes to the open definition screens are cancelled. Changes currently in definition
facility list screens, for example, changes to previously closed definition screens, are not cancelled. Those
screens and all other open screens are treated as if END (PF03/PF15) has been entered.
Note: The =X command is intentionally not supported on certain screens.

70
Control-M/Analyzer User Guide

Screen Layout
Most IOA screens are divided into the four basic areas described in Table 29. The example illustrated in
Figure 18 is the IOA Log screen.
Table 29 Basic IOA Screen Areas

Screen Area Description

Screen Description This line at the top of the screen describes the purpose of the
and Message Line screen (in the example screen, the "IOA Log.") A screen identifier
may appear in the upper right corner (in the example screen, 5).
This line is also used to display messages.

Screen Header and This area is used for online commands, and, where applicable,
Command Area headings of the screen data.

Data Area On some screens, the data area can be scrolled. For more
information, see Scrolling Commands (on page 74).

Screen Bottom This area of the screen usually contains a list of available commands
or options (In the example screen, SHOW, GROUP, CATEGORY, and
SHPF), or a brief explanation about screen usage. The current time
is displayed in the lower right corner.

Figure 18 IOA Log Screen


FILTER: ---------------- IOA LOG -------------------------------(5)
COMMAND ===> SCROLL===> CRSR
SHOW LIMIT ON ==> DATE 291201 - 010102
DATE TIME ODATE USERID CODE ------ M E S S A G E --------------------
311201 184915 311201 K48 SUB13AI JOB K48RUN1 / OID=005W9 SUBMITTER STARTED
PROCESSING JOB ON SYSTEM: OS35
311201 184915 311201 K48 SUB133I JOB K48RUN1 K48RUN /27255 OID=005W9
SUBMITTED FROM LIBRARY (P) K48.LIB.JOB
311201 184918 311201 K48 SPY28GI JOB K48RUN1 K48RUN /27255 OID=005W9 TAPE
DRIVE UNITS USED=00 00
311201 184918 311201 K48 SPY281I JOB K48RUN1 K48RUN /27255 OID=005W9 START
01365.1849 STOP 01365.1849 CPU 0MIN
00.05SEC SRB 0MIN 00.00SEC 0.00 4AOS35
311201 184918 311201 K48 SPY254I JOB K48RUN1 K48RUN /27255 OID=005W9
SCANNED
311201 184918 311201 K48 SEL216W JOB K48RUN1 K48RUN /27255 OID=005W9
UNEXPLAINED COND CODE 0015 STEP EXEC /
311201 184918 311201 K48 SEL214I JOB K48RUN1 K48RUN /27255 OID=005W9 RERUN
NEEDED
311201 184918 311201 K48 SEL205I JOB K48RUN1 K48RUN /27255 OID=005W9 RERUN
IN PROCESS USING MEM K48RUN1
311201 184918 311201 K48 SEL286I JOB K48RUN1 K48RUN /27255 OID=005W9
WAITING FOR CONFIRMATION
CMDS: SHOW, GROUP, CATEGORY, SHPF 08.57.11

71
Control-M/Analyzer User Guide

Commands and PFKeys


Commands are entered by typing a command in the COMMAND field and then pressing Enter, or by
pressing a predefined PFKey, or a combination of both.
It is not necessary to enter the full command name; the shortest unique abbreviation of the command is
sufficient. If the abbreviation is ambiguous, an appropriate message is displayed in the message area.
IOA commands are flexible; you can change command syntax or provide aliases (synonyms) to suit your
site. If you want to add or change a command syntax, consult BMC Customer Support. The examples
provided in this chapter exhibit the original command syntax supplied with this INCONTROL product.
PFKey command assignments can be site-customized. It is possible to assign PFKeys differently for each
screen. To change PFKey command assignments, see your INCONTROL administrator.
Supplied PFKey definitions are consistent throughout most of the screens. For example: PF08/PF20 is
used to scroll down (forward) on all INCONTROL screens where scrolling is possible.
Common PFKey definitions are:
Table 30 Common PFKey definitions:

PFKey Description

PF01/PF13 HELP

PF02/PF14 SHOW (where applicable)a

PF03/PF15 END (exit current screen and go back one level)

PF04/PF16 RESET (where applicable)b

PF05/PF17 FIND (where applicable)

PF06/PF18 =6 (transfer to the TSO screen or application, or to the Utilities


screen)c

PF07/PF19 UP (scroll backward)

PF08/PF20 DOWN (scroll forward)

PF10/PF22 LEFT or PREV (where applicable)

PF11/PF23 RIGHT or NEXT (where applicable)

PF12 RETRIEVE (Retrieves a sequence of commands and options entered


by the user during the current session. These commands and
options are displayed in reverse order, on the command line of the
current screen.)

PF24 SHPF

72
Control-M/Analyzer User Guide

To see the PFKey assignment of the screen with which you are working, type the reserved command
SHPF in the command line and press Enter. A window describing the current PFKey assignment appears
on the screen. Press Enter again to close the window.
Figure 19 PFKey Assignment Window
FILTER: ---------------- IOA LOG -------------------------------(5)
COMMAND ===> SCROLL===> CRSR
SHOW LIMIT ON ==> DATE 291201 - 010102
DATE TIME ODATE USERID CODE ------ M E S S A G E --------------------
311201 184915 311201 K48 SUB13AI JOB K48RUN1 / OID=005W9 SUBMITTER STARTED
PROCESSING JOB ON SYSTEM: OS35
311201 184915 311201 K48 SUB133I JOB K48RUN1 K48RUN /27255 OID=005W9
SUBMITTED FROM LIBRARY (P) K48.LIB.JOB
311201 184918 311201 K48 SPY28GI JOB K48RUN1 K48RUN /27255 OID=005W9 TAPE
DRIVE UNITS USED=00 00
311201 184918 311201 K48 SPY281I JOB K48RUN1 K48RUN /27255 OID=005W9 START
+----------------------------------------------------------------------------+
| |
| ENTER ENTER PF13 HELP |
| PF01 HELP PF14 SHOW |
| PF02 SHOW PF15 END |
| PF03 END PF16 RESET |
| PF04 RESET PF17 FIND |
| PF05 FIND PF18 =6 |
| PF06 =6 PF19 UP |
| PF07 UP PF20 DOWN |
| PF08 DOWN PF24 SHPF |
| PF12 RETRIEVE |
+----------------------------------------------------------------------------+

If you type text in the COMMAND field and press a PFKey, the text in the COMMAND field is treated as a
subparameter of the command assigned to the PFKey.
Two additional key definitions are:
Table 31 Additional Key Assignments

Key Description

PA1 ABORT – forced exit


If you press PA1 while in AutoRefresh mode (described in
AutoRefresh Mode (on page 78)), AutoRefresh mode is canceled.

PA2 Under native TSO and ROSCOE, the first time you press this key,
the screen is refreshed. The second consecutive time, a copy of the
screen is sent to be printed, or to a file, using DD statement
PRTDBG. For terminal models supporting PA3, the PA3 key is
defined in exactly the same way as PA2.
When the IOA online facility is activated as an ISPF application, PA2
is controlled by ISPF, and only refreshes the screen. To print the
screen, see IOA Under ISPF (on page 78). Under other online
environments, such as CICS and VTAM, PA2 serves as a refresh
only. Usually one of the PA keys is assigned a local print function.

For information on changing IOA PFKey definitions, see the appendix in the INCONTROL for z/OS
Administrator Guide that deals with modifying IOA Online facility commands.

73
Control-M/Analyzer User Guide

Scrolling Commands
Scrolling conventions are very similar to the ISPF conventions of IBM. Two basic commands are used for
scrolling:
Table 32 Scrolling Commands

Command PFKey Description

UP (PF07/PF19) Scroll up (backward).

DOWN (PF08/PF20) Scroll down (forward).

The commands can be specified by typing directly in the COMMAND field or by pressing the predefined
PFKey.
The scrolling amount is determined by the content of the SCROLL field in the right corner of the screen
header. Valid scrolling amounts:
Table 33 Scrolling Amounts in the SCROLL Field

Scrolling Amount Description

PAGE Scroll a full page.

HALF Scroll a half page.

CRSR Scroll by cursor position. If the cursor is outside the data area, a full
page is scrolled.

MAX Scroll maximum available (for example, UP MAX will scroll to the
top).

It is only necessary to type the first letter of the new amount in the SCROLL field in order to change the
scrolling amount.
A scrolling amount other than that shown in the SCROLL field can be used by specifying the amount
directly after the scroll command itself, or by specifying the scroll amount in the COMMAND field and
pressing the appropriate scrolling PFKey. The scrolling amount in the SCROLL field remains unchanged.
Example
If PAGE is the value in the SCROLL field, to scroll to the bottom, type M (MAX) in the COMMAND field and
press PF08/PF20 (DOWN).

74
Control-M/Analyzer User Guide

LOCATE Command
The LOCATE command, and its abbreviation, L, can be used to search for items in the NAME field in all
"directory type" screens that contain scrollable data, such as the Calendar List screen. The syntax of the
command is
LOCATE string

where string is the search string. Apostrophes (‘single quotes’) or quotation marks ("double quotes") are
not required.
The search proceeds from the top of the list to the first item in the list that starts with the specified string.
The cursor is positioned on the OPTION field at the beginning of the line containing the string, if found, or
on the OPTION field of the alphabetically closest preceding value if the specified value is not found.

FIND Command
The FIND command, and its abbreviation, F, can be used in all screens that contain scrollable data to find
and display the next occurrence of a character string. The syntax of the command is
FIND string [fromcol] [tocol] [PREV]

where
 string is the search string
Mandatory.
 fromcol is the first column in the search range
Optional.
 tocol is the last column in the search range
Optional.
 PREV is the indicator that the search must move backward, instead of forward, from the current
cursor position
Optional.
General Rules
If the string contains blanks, enclose the string with apostrophes (‘single quotes’) or quotation marks
("double quotes"). For example:
FIND 'WAIT SCHEDULE'

The column range searched can be limited by entering fromcol or tocol values, or by entering both
fromcol and tocol values.
The search for the string proceeds from the current cursor position forward, or backward if PREV is
entered. If the string is found, the cursor is positioned at the start of the string.
To repeat the find, to the next or previous occurrence of the string, press PF05/PF17.
Note: The following situations outline where the FIND command can, or should, be further modified to
enhance its functionality.

75
Control-M/Analyzer User Guide

 Some screens enable the user to limit the number of lines searched by a FIND command. This is
discussed in the relevant screen descriptions.
 In some screens, the FIND command does not detect information that is to the right or left of the
information displayed in the monitor. To ensure detection of the desired string, the screen must be
displayed in wraparound mode, when available, before executing the FIND command.
Text String Searches
The FIND command can also be used to search for text strings, in which case the command will find all
instances of the string, regardless of whether the characters within the string are lowercase, uppercase,
or mixed case. To search for a text string, include the letter T immediately before a quoted string.
For example,
FIND T'WAIT SCHEDULE'

will find WAIT SCHEDULE, and it will also find wait schedule, and Wait Schedule, and any other case
variant.
Text string searches are the default. If your system default is for text strings, You do not need to include
the T if you perform a text string search. Your INCONTROL administrator can change the default to
character string. In this case you do not need to include the C if you perform a character string search.
Character String Searches
The FIND command can be used to search for character strings, in which case the command will find all
instances of the string, but only where the string contains characters that match the case specified. To
search for a character string, include the letter C immediately before a quoted string.
For example,
FIND C'WAIT SCHEDULE'

will find WAIT SCHEDULE, but it will not find wait schedule, or Wait Schedule, or any other case variant.

CANCEL and RESET Commands


CANCEL and RESET commands are entered in the COMMAND field.
The CANCEL command cancels changes made in a definition screen, such as the IOA Calendar Definition
screen, and exits the screen.
The RESET command (PF04/PF16) cancels Edit environment options specified in a definition screen. It
does not cancel changes already made and it does not exit the screen or cancel Edit environment mode.
For more information about the Edit environment, see A Editing Rule Definitions in the IOA Edit
Environment (on page 660).
The RESET command (PF04/PF16) can also be used in most windows, for example, the Show Screen
Filter window, to cancel changes and close the window.

76
Control-M/Analyzer User Guide

Online Help
The following types of online help are available for INCONTROL screens:

Screen Help
Provides information about the entire screen. This help is available on all INCONTROL screens and is
accessed by pressing the HELP key (PF01/PF13) while the cursor is positioned on the COMMAND field in
the screen.

Line-Sensitive Help
Provides information about the fields on a particular line on a screen. This help is available on several
INCONTROL screens. It is accessed by pressing the HELP key (PF01/PF13) while the cursor is positioned
on the desired line of the screen.
Figure 20 IOA Help Screen
------------------------------ IOA HELP SCREEN --------------------- (CTMHDT2 )
COMMAND ===> SCROLL===> CRSR

Calendar List Screen


====================

The Calendar List screen displays a list of calendars (members) in the


specified library. This screen can be entered directly from the entry
panel or upon exiting the Year List screen.

By default, only calendar names are listed in the screen. However, if


the default has been modified at time of installation, statistical
information is displayed for each calendar name.

Use the scrolling PFKeys to scroll forward (PF08/PF20) and backward


(PF07/PF19) on the Calendar List.

To return to the entry panel, press END (PF03/PF15).

Options of the Calendar List Screen


-----------------------------------
To request one of the following options, specify the option in the OPT
ENTER END OR PF03/PF15 TO EXIT THE HELP SCREEN 08.55.40

If line-sensitive help is not supported in a screen, pressing the HELP key (PF01/PF13) from anywhere in
the screen displays the beginning of the Help panel.
Help can be scrolled using standard scrolling conventions.
To return to the original screen, use the END command (PF03/PF15).
The Help member name appears on the right in the Help screen header. Members containing the Help
descriptions can be found in the IOA MSG library.

77
Control-M/Analyzer User Guide

AutoRefresh Mode
Certain INCONTROL screens, as noted in this chapter where appropriate, support AutoRefresh mode. A
screen display in AutoRefresh mode is automatically updated periodically with the most current data.
AutoRefresh mode can only be activated under native TSO or under ISPF. AutoRefresh mode is activated
by the AUTO command. The format of the command is
AUTO n

where n is any number of seconds from 1 through 99.


The screen is updated when the AUTO command is issued, and then periodically updated according to the
interval (in seconds) specified in the AUTO command. A counter at the top of the screen displays the
number of times the screen has been refreshed.
Example
The AUTO 5 command refreshes the screen every 5 seconds.

Cancelling AutoRefresh Mode


Under native TSO, the recommended method of cancelling AutoRefresh mode is as follows:
 For short interval values – Press Enter. Whenever Enter is pressed, or a command is issued,
AutoRefresh mode is automatically cancelled at the end of the current interval.
 For long interval values – Press Attn (PA1) once.
Under ISPF, press Attn (PA1) or Esc once to cancel AutoRefresh mode.
Note: When using a terminal emulation program, you must ensure that the Esc key is properly mapped
and sent as an Attn (PA1) key.

IOA Under ISPF


The IOA Online facility can be activated as an ISPF application. As such, it can work in ISPF split screen
mode like any other ISPF application.
WARNING: Multiple calls to the IOA ISPF interface can be performed in ISPF split screen mode as long as
all invocations are for the same IOA environment. Otherwise, the results may be unpredictable.
The command line of the IOA Online facility is controlled by IOA. It is not possible to enter ISPF
commands in an IOA screen. Two ISPF commands must be defined to PFKeys:
Table 34 ISPF Commands that must be defined for PFKeys

Command PFkey
SPLIT (usually PF02/PF14)
SWAP (usually PF09/PF21)

The rest of the PFKeys are controlled by IOA PFKey definitions, which are in the IOA PARM library.
It is possible to assign TSO/ISPF commands such as PRINT to PFKeys, or to change PFKey definitions by
performing the following steps:

78
Control-M/Analyzer User Guide

1. Exit from IOA and ISPF to the READY prompt.


2. Type the following command and press Enter:
ISPSTART PANEL(ISR@PRIM) NEWAPPL(CTM)
This command brings you to ISPF.
3. Type the KEYS command and press Enter. A set of key definitions is displayed.
4. Modify the key definitions as desired and exit from ISPF.
Note: ISPF KEY definitions for the following ISPF commands take precedence over IOA PFKey definitions:
SPLIT, SWAP, KEYS, PRINT, PFSHOW. For example, if PF02 is defined as SPLIT in ISPF, an IOA definition
for PF02 is ignored in online screens. For all other ISPF commands, such as UP or DOWN, the key
definitions in ISPF are ignored and the PFKey is interpreted according to the definition in the IOA Online
facility.
Under ISPF, IOA Option 6 activates the Online Utilities panel, which is described in IOA Online Utilities
Menu (on page 219). For more information about these utilities, see the INCONTROL for z/OS Utilities
Guide.
For more information on changing IOA PFKey definitions, see the appendix in the INCONTROL for z/OS
Administrator Guide that deals with modifying IOA Online Facility Commands.

IOA Editor
The IOA Editor enables you to edit members of a partitioned data set (PDS) using an editor similar to the
ISPF editor. Enter EDMEM in the command line of any screen to display the Edit Entry Panel window, as
illustrated in Figure 21.
Figure 21 IOA Editor Edit Entry Panel
Figure 21 IOA Editor Edit Entry Panel
--------------------- IOA PRIMARY OPTION MENU ------------------(1)
OPTION ===> USER N06

IOA CONTROL-D/V CONTROL-O


4 COND/RES A MISSION STATUS OR RULE DEFINITION
5 +--------------------------------------------------------------+ICS
6 | EDIT ENTRY PANEL |
7 | |LOG
8 | LIBRARY ==> |OPTS
IV | |US
| MEMBER ==> |R
| |
| FILL IN PARAMETERS AND PRESS ENTER TO CONTINUE OR PF3 TO EXIT|
CONTR| |
+--------------------------------------------------------------+
2 JOB SCHEDULE DEF BB BALANCING STATUS TR RULE DEFINITION
3 ACTIVE ENV. BM MISSION DEF TP POOL DEFINITION
C CMEM DEFINITION BV DB VARIABLE DEF TV VAULT DEFINITION
BR RULE DEFINITION TI INQ/UPD MEDIA DB
BA RULE ACTIVITY TC CHECK IN EXT VOL

COMMANDS: X - EXIT, HELP, INFO OR CHOOSE A MENU OPTION 19.12.05

To create a new member or edit an existing member, fill in the LIBRARY and MEMBER parameters and
press Enter. The IOA Editor screen is opened for editing, as illustrated in Figure 22.

79
Control-M/Analyzer User Guide

Note: If the member already exists in the specified library, the member is displayed for editing in the IOA
Editor. Similarly, if you accessed the IOA Editor screen from line option J in either screen 2 or screen 3,
the member in the library referred to in the schedule definition member will be displayed for editing.
Figure 22 IOA Editor
---------------------------- I O A E D I T O R ------------------- (EDMEM)
COMMAND ===> SCROLL===> CRSR
ROW PROD.V610.DEMO(TEST) COL 001 072

......
......
......
......
......
......
......
......
......
......
************************ B O T T O M O F D A T A **************************

OPTIONS: I INSERT D DELETE R REPEAT C COPY M MOVE UC/LC UPPER/LOWER CASE

80
Control-M/Analyzer User Guide

IOA Editor PFKey Functions


While working within the IOA Editor, PFKeys perform the functions described in Table 35.
Table 35 PFKey Functions Within the IOA Editor Screen

PFKeys Description

PF01/PF13 Activates online help.

PF02/PF14 Saves the current member.

PF03/PF15 Terminates the editing session. If the edited member has been
changed the member will be saved automatically.

PF04/PF16 Cancels the editing session without saving changes.

PF05/PF17 Invokes the Find facility.

PF07/PF19 Scrolls forward.

PF08/PF20 Scrolls backward.

PF10/PF22 Scrolls left.

PF11/PF23 Scrolls right.

Commands of the IOA Editor Screen


Table 36 describes editing commands that can be executed by entering the command in the COMMAND
line.
Table 36 IOA Editor Command Line Commands

Command Description

SAVE Saves all new data without terminating the edit session.

CANCEL Terminates the edit session without saving new data.

COPY Enables you to import a member from a specific library.

Table 37 describes editing commands that can be executed by entering the command in the leftmost
position of the applicable row.

81
Control-M/Analyzer User Guide

Table 37 IOA Editor Row Commands

Command Description

I Inserts a new line below the current line.


To insert more than one line for new data, enter Inn, where nn
indicates the number of new lines to be inserted below the current
line.

D Deletes the current line.


To delete more than one line, enter Dnn, where nn indicates the
number of lines to be deleted below the current line.
You can delete a block of lines by typing DD at the beginning of the
first line of the block, and then entering DD at the beginning of the
last line of the block.

R Repeats the current line.


To repeat a single line one or more times, enter Rnn, where nn
indicates the number of times the current line is to be repeated.
You can repeat a block of lines by typing RR at the beginning of the
first line of the block, and then entering RR at the beginning of the
last line of the block.

C Identifies the source line for a copy operation.


To copy more than a single line, enter Cnn, where nn indicates the
number of lines to be copied.
You can also copy a block of lines by typing CC at the beginning of
the first line of the block, and then entering CC at the beginning of
the last line of the block.

M Identifies the source line for a move operation.


To move more than a single line, enter Mnn, where nn indicates the
number of lines to be moved.
You can also move a block of lines by typing MM at the beginning of
the first line of the block, and then entering MM at the beginning of
the last line of the block.

A Identifies the destination of a copy or move operation.


When a line or block of lines has been selected for copying or
moving, enter A at the point after which the copied lines are to be
inserted.

B Identifies the destination of a copy or move operation.


When a line or block of lines has been selected for copying or
moving, enter B at the point before which the moved lines are to be
inserted.

LC Changes text in a line from uppercase to lowercase.


To change text in more than a single line to lowercase, enter LCnn,
where nn indicates the number of lines to be changed to lowercase.

82
Control-M/Analyzer User Guide

Command Description

UC Changes text in a line from lowercase to uppercase.


To change text in more than a single line to uppercase, enter UCnn,
where nn indicates the number of lines to be changed to uppercase.

IOA SET Command Panel


The IOA SET Command Panel enables you to set and stop TRACE levels, choose the language that is used
in online screens and to set a dollar sign representation that will be used in online screens for system
variables of type %%$VAR. Enter SET in the command line of any screen to display the SET Command
Panel window, as shown in Figure 23.
Figure 23 IOA SET Command Panel
+-----------------------------------------------------------------------------------+
| SET Command Panel |
| |
| |
| TRACE level , ON (Trace level 001-512, ON or OFF) |
| |
| |
| LANGUAGE ENG - English |
| FRA - French |
| GER - German |
| JPN - Japanese |
| |
| |
| SPECIAL CHARACTERS: Dollar Current representation is "$"(X'5B') |
| |
| |
| FILL IN PARAMETERS AND PRESS ENTER TO CONTINUE OR PF3 TO EXIT |
| |
+-----------------------------------------------------------------------------------+

The process of setting TRACE levels and turning off a particular TRACE, and the process of setting
language preferences for online screens and messages, begins in the SET Command Panel.

Using the SET Command Panel to set and end TRACE Levels
Setting the TRACE level can help you monitor certain IOA Online facility and INCONTROL functions, such
as security checks.
The following steps explain how to set or turn off a TRACE level:
1. Type a TRACE level number, from 1 through 256, in the TRACE level field of the SET Command
Panel.
2. In the (Trace level 1-256, ON or OFF) field, type ON to set a TRACE level, or OFF to turn off a TRACE
level.
3. Press Enter to confirm the setting, in which case the following message is displayed:
CTMA2AI TRACE LEVEL nnn WAS SET xxx

83
Control-M/Analyzer User Guide

where
• nnn is the TRACE level number
• xxx indicates whether the TRACE level was set ON or turned OFF
Note: TRACE level settings take effect immediately.

Using the SET Command Panel to set a dollar sign representation


Setting the dollar sign representation influences how System variables are shown in online screens.
The following steps explain how to set the dollar sign representation:
1. Type a $ character in the Dollar field using your keyboard.
2. Press Enter to confirm the setting, in which case the following message is displayed:
CTMA2DI THE NEW DOLLAR REPRESENTATION IS "c"(X'yy')
where
• c is $ character you set
• yy is the EBCDIC hexadecimal code for $
Note: There are differences in the EBCDIC hexadecimal code for the $ (dollar sign) character on
keyboards that have been adapted to show local or national symbols.

Using the SET Command Panel to set language preferences


Setting the LANGUAGE influences the online screens and messages in subsequent sessions.
The following steps explain how to set language preferences:
1. In the LANGUAGE field, type one of the following sets of characters to select a language preference:
• ENG, to set English as the preferred language
• FRA, to set French as the preferred language
• GER, to set German as the preferred language
• JPN, to set Japanese as the preferred language
2. Press Enter to confirm the setting, in which case the following message is displayed:
CTMA27I THE NEW LANGUAGE WILL BE USED FROM THE NEXT LOGON TO IOA
Note: Language preference settings do not take effect until your next logon to the system.

84
Control-M/Analyzer User Guide

IOA TSO Command Processor Screen


The IOA TSO Command Processor screen can be entered only when the IOA Online facility is activated as
a TSO application. It cannot be entered when the IOA Online facility is activated as an ISPF application or
activated under a non-TSO environment.
The TSO screen enables activation of any TSO command without exiting the IOA Online facility. For
example, a typical program activated under the TSO screen is ISPF. Therefore all ISPF/PDF facilities and
functions, such as editing a member or scanning job output, can be activated while you are working
under the IOA Online facility.
To activate a TSO command, type the command in the COMMAND field and press Enter.
Figure 24 IOA TSO Command Processor Screen
-------------------------- IOA TSO COMMAND PROCESSOR -----------------------(6)
COMMAND ===> ISPF

PLEASE ENTER TSO COMMAND 15.32.52

Note: CLISTs cannot be activated from the TSO screen. To activate a CLIST, first activate ISPF and then
execute the CLIST under ISPF.
TSO commands can also be activated directly from any IOA online screen by typing TSO in the COMMAND
field.

Transfer of Control Between the TSO Application and the IOA Online
Facility
You can return to the IOA Online facility from the TSO application by simply exiting the TSO application in
a normal manner. However, this method can be time consuming and inconvenient if an ISPF application
or a similar TSO application is activated.
If the TSO application can issue a TSO command, it is possible to transfer control to the IOA Online
facility, and vice versa, without exiting the TSO application.
While working under the TSO application, for example, under ISPF, issue the command:
TSO CTMTTRA {n | =n}

where n is the online screen number.

85
Control-M/Analyzer User Guide

The requested screen is displayed as it was when you transferred from it.
To return to the TSO application, use the =6 command (PF06/PF18). The application remains in the
same state as when you transferred from it.
BMC recommends that you simplify transfer between screens by permanently assigning one of your
PFKeys under ISPF (or SDSF, and so on) to the command TSO CTMTTRA. Once this key assignment is
made, you no longer need to type the full transfer command. Instead, you merely type the IOA option
number or code in the COMMAND field and press the assigned PFKey. You are transferred to the desired
screen.
Note: You must activate ISPF under the IOA Online facility if you want to use the control transfer feature.

Database Variable Definition Facility


The Control-M/Analyzer Database facility is composed of a series of screens that enable you to view,
create and modify the parameters of Database variables.

Database Variable Definition


Database variable parameters are stored in the Control-M/Analyzer Database. The number of Database
variables that can be defined is limited only by the size of the Control-M/Analyzer Database.
To enter the Database facility, select option BV on the IOA Primary Option menu. The Control-M/Analyzer
Database facility entry panel is displayed.
Note: Throughout this topic, the term "variables" means "Database variables" unless indicated otherwise.

86
Control-M/Analyzer User Guide

Entry Panel
Figure 25 Database Variable Facility Entry Panel
------- Control-M/Analyzer DATABASE FACILITY - ENTRY PANEL --------------(BV)
COMMAND ===>

SPECIFY GROUP, VARIABLE NAME

GROUP ===> (Blank for Group selection list)

VARIABLE ===> (Blank for Variable selection list)

("*" for Variable/Group prefix)

USE THE COMMAND "SHPF" TO SEE PFK ASSIGNMENT 10.39.57

 To display the list of groups in a library: Type the library name and press Enter.
 To display the list of variables of a specific group: Type the library name, type the group name and
press Enter. If the group name does not exist, the screen for defining a new group is displayed.
 To display the details of a specific variable: Type the group name, type the variable name, and press
Enter. If the variable for the specified group does not exist, the screen for defining a new variable in
the group is displayed.
Note: If you enter the screen for defining a new variable and want to leave it without defining a variable,
use the RESET command or press PF04/PF16.
When specifying group and variable names in the entry panel, mask character * is supported.

87
Control-M/Analyzer User Guide

Examples
Table 38 Group and Variable Names – Mask Character Examples

Group Variable Result

INV* Groups such as INV, INV1, INV2, INV3,


INVENTORY, and INVOICING are listed.

INV Only group INV is listed.

INV TOT* Variables in group INV such as TOT, TOT1,


TOT2, and TOTAL are listed.

INV TOT The Database Variable Definition screen is


displayed. Parameters for variable TOT in
group INV may be edited.

Note: A mask character can be used in the specification of a variable name only if the group name is
specified without a mask character.

Database Facility – Group List


The screen displays a list of groups. This screen can be entered using the entry panel or when returning
from the Variable List screen.
Figure 26 Control-M/Analyzer Data Base Facility Screen
LIST OF GROUPS ----- CONTROL-M/ANALYZER DATA BASE --------------------------(BV)
COMMAND ===> SCROLL===> CRSR
OPT NAME DESCRIPTION MODE
ACCT_INV ACCOUNTING DEPT - INVENTORY ACTIVE
ACCT_PAYROLL ACCOUNTING DEPT - PAYROLL DEFINE
ACCT_PRINT ACCOUNTING DEPT - PRINTED FORMS ACTIVE
ACCT_TOTALS1 ACCOUNTING DEPT - TOTALS GROUP 1 ACTIVE
ACCT_TOTALS2 ACCOUNTING DEPT - TOTALS GROUP 2 ACTIVE
ACCT_TOTALS3 ACCOUNTING DEPT - TOTALS GROUP 3 DEFINE
ACCT_TOTALS4 ACCOUNTING DEPT - TOTALS GROUP 4 SIMULATE
ADMIN_INV ADMINISTRATION - INVENTORY DEFINE
ADMIN_PRINT ADMINISTRATION - PRINTED FORMS ACTIVE
ADMIN_SP1 ADMINISTRATION - SPECIAL PROJECTS 1 ACTIVE
ADMIN_SP2 ADMINISTRATION - SPECIAL PROJECTS 2 SIMULATE
ADMIN_SP3 ADMINISTRATION - SPECIAL PROJECTS 3 DEFINE
CURRENCY CURRENCY EXCHANGE RATES ACTIVE
DAVIS_GROUP DAVIS GROUP - FOR TESTING PURPOSES SIMULATE
DOLRRATE DOLLAR EXCHANGE RATES ACTIVE
DOLRSAVE OLD DOLLAR EXCHANGE RATES DEFINE
FRANK_GROUP FRANK'S GROUP - FOR TESTING PURPOSES SIMULATE
GEORGE_GROUP GEORGE'S GROUP - FOR TESTING PURPOSES DEFINE
GRAPHIX_INV GRAPHICS DEPT - INVENTORY DEFINE
GRAPHIX_PRINT GRAPHICS DEPT - PRINTED FORMS ACTIVE
OPTIONS: S SELECT I INSERT U UPDATE 10.47.06

Use the scrolling PFKeys to scroll the Group List forward (PF07/PF19) and backward (PF08/PF20).
A short description is displayed for each group. This description can be specified either when creating a
new group, or through Option U – the Update option. For more information, see Options of the Group List
Screen (on page 89).

88
Control-M/Analyzer User Guide

The implementation level – mode – of the group is also displayed. The mode can be specified either when
creating a new group, or through Option U – the Update option. For more information, see Options of the
Group List Screen (on page 89). The following three modes are provided by Control-M/Analyzer:
 Define mode
 Simulate mode
 Active mode
For additional information on implementation levels, see Group Concept and Group Modes (on page 33).

Options of the Group List Screen


To use one of the options described in Table 39, specify the option in the OPT field to the left of the
group name and press Enter
Table 39 Options of the Group List Screen

Option Description

S (SELECT) See a list of Database variables in a group.

I (INSERT) Insert a new group in the list. The New Group window appears,
prompting you to specify the group name, description, and mode.
See "Inserting a New Group" below.
The new group is added after the group marked "I". When the
Group List screen is redisplayed, the groups are listed in
alphabetical order.

U (UPDATE) Update the description of the current group. For more information,
see Updating Group Descriptions and Modes (on page 91).

89
Control-M/Analyzer User Guide

Inserting a New Group


Specify I to insert a new group. The New Group window adds new groups to the Group List. The mode of
the group is also specified in this window.
Figure 27 New Group Window
LIST OF GROUPS ----- CONTROL-M/ANALYZER DATA BASE FACILITY------------------(BV)
COMMAND ===> +-----------------------------------------------------------+ SR
OPT NAME | PLEASE FILL IN DESCRIPTION FOR THE NEW GROUP |
ACCT_INV | |
ACCT_PAYRO| NEW GROUP NAME CREATE (Y/N) |
I ACCT_PRINT| |
ACCT_TOTAL| DESCRIPTION |
ACCT_TOTAL| GROUP MODE ( D -DEFINE, A -ACTIVE, S -SIMULATE ) |
ACCT_TOTAL| |
ACCT_TOTAL+-----------------------------------------------------------+
ADMIN_INV ADMINISTRATION - INVENTORY DEFINE
ADMIN_PRINT ADMINISTRATION - PRINTED FORMS ACTIVE
ADMIN_SP1 ADMINISTRATION - SPECIAL PROJECTS 1 ACTIVE
ADMIN_SP2 ADMINISTRATION - SPECIAL PROJECTS 2 SIMULATE
ADMIN_SP3 ADMINISTRATION - SPECIAL PROJECTS 3 DEFINE
CURRENCY CURRENCY EXCHANGE RATES ACTIVE
DAVIS_GROUP DAVIS GROUP - FOR TESTING PURPOSES SIMULATE
DOLRRATE DOLLAR EXCHANGE RATES ACTIVE
DOLRSAVE OLD DOLLAR EXCHANGE RATES DEFINE
FRANK_GROUP FRANK'S GROUP - FOR TESTING PURPOSES SIMULATE
GEORGE_GROUP GEORGE'S GROUP - FOR TESTING PURPOSES DEFINE
GRAPHIX_INV GRAPHICS DEPT - INVENTORY DEFINE
GRAPHIX_PRINT GRAPHICS DEPT - PRINTED FORMS ACTIVE
OPTIONS: S SELECT I INSERT U UPDATE 19.04.35

Enter the group name, group description, and group mode in their respective fields. You must enter Y
(Yes) or N (No) in the CREATE field. Press Enter to return to the Group List screen.
The new group is listed after the group marked "I". The next time the Group List screen is displayed, the
list is alphabetized.

90
Control-M/Analyzer User Guide

Updating Group Descriptions and Modes


Specify U to update the definition or mode of a group. The Update Group Description and Mode window is
used for this purpose.
Figure 28 Update Group Description and Mode Window
LIST OF GROUPS ----- CONTROL-M/ANALYZER DATA BASE FACILITY -----------------(BV)
COMMAND ===> +-----------------------------------------------------------+ SR
OPT NAME | YOU MAY UPDATE THE GROUP DESCRIPTION AND MODE |
U ACCT_INV | |
ACCT_PAYRO| GROUP NAME ACCT_INV UPDATE (Y/N) |
ACCT_PRINT| |
ACCT_TOTAL| DESCRIPTION ACCOUNTING - INVENTORY |
ACCT_TOTAL| GROUP MODE A ( D -DEFINE, A -ACTIVE, S -SIMULATE ) |
ACCT_TOTAL| |
ACCT_TOTAL+-----------------------------------------------------------+
ADMIN_INV ADMINISTRATION - INVENTORY DEFINE
ADMIN_PRINT ADMINISTRATION - PRINTED FORMS ACTIVE
ADMIN_SP1 ADMINISTRATION - SPECIAL PROJECTS 1 ACTIVE
ADMIN_SP2 ADMINISTRATION - SPECIAL PROJECTS 2 SIMULATE
ADMIN_SP3 ADMINISTRATION - SPECIAL PROJECTS 3 DEFINE
CURRENCY CURRENCY EXCHANGE RATES ACTIVE
DAVIS_GROUP DAVIS GROUP - FOR TESTING PURPOSES SIMULATE
DOLRRATE DOLLAR EXCHANGE RATES ACTIVE
DOLRSAVE OLD DOLLAR EXCHANGE RATES DEFINE
FRANK_GROUP FRANK'S GROUP - FOR TESTING PURPOSES SIMULATE
GEORGE_GROUP GEORGE'S GROUP - FOR TESTING PURPOSES DEFINE
GRAPHIX_INV GRAPHICS DEPT - INVENTORY DEFINE
GRAPHIX_PRINT GRAPHICS DEPT - PRINTED FORMS ACTIVE
OPTIONS: S SELECT I INSERT U UPDATE 18.30.39

Modify the group description and/or the group mode in their respective fields. You must enter Y (Yes) or
N (No) in the UPDATE field. Press Enter to return to the Group List screen.

91
Control-M/Analyzer User Guide

Database Facility – Variable List


The screen displays the list of Database variables of a group. This screen can be entered directly using
the Database facility entry panel, through the Group List screen, or when returning from the Database
Variable Definition screen.
Use the scrolling conventions to scroll the Variable list forward and backward.
Figure 29 Database Variable Definition Screen
LIST OF VARIABLES CONTROL-M/ANALYZER DATA BASE GROUP: ACCT_INV
COMMAND ===> SCROLL===> CRSR
OPT NAME ----------------------------------------------------------------------
EMP_PAYROLL
ESTIMATE_PAYROLL
GROSS_PROFIT
MAN_PAYROLL
NET_PROFIT
PAYROLL_TOT
PROJECTED_PROF
TAX_RATE
===== >>>>>>>>>>>>>>>>>> NO MORE VARIABLES IN GROUP <<<<<<<<<<<<<<<<< =====

OPTIONS: S SELECT I INSERT V VIEW G GRAPH 12.08.35

92
Control-M/Analyzer User Guide

Options of the Variable List Screen


To use one of the options described in Table 40, specify the option in the OPT field to the left of the
variable name and press Enter.
Table 40 Options of the Variable List Screen

Option Description

S (SELECT) Edit details of the specific Database variable. The Database Variable
Definition screen appears.

I (INSERT) Insert a new variable in the list. The Database Variable Definition
screen appears, with the same details as the variable marked "I",
but the VARIABLE and DESCRIPTION parameters are empty for you
to fill in.
The new Database variable is initially added after the variable
marked "I". When the Variable List is redisplayed, the variables are
listed in alphabetical order.

V (VIEW) Details of the values of the specific Database variable. The Variable
Display screen appears.

G (GRAPH) Display the View Graph by Variable Generations screen. The screen
lists each generation of a variable with its value and provides a
histogram that graphically illustrates numeric values.

Database Variable Definition Screen


This screen defines, displays, and modifies parameters of the Database variables of a specific group. You
can enter this screen directly from the Database facility entry panel or from the Variable List screen.
For a detailed explanation of the parameters, see Chapter 3, "Control-M/Analyzer Variables."
To delete a parameter on the screen, erase it by pressing the EOF key or blank it out. If additional
operations are required, Control-M/Analyzer issues appropriate instructions.
Database variable parameters are divided into the following three groups:
1. Basic Parameters (see NAME field through DESC field in Figure 30)
2. Generation Parameters (see MAXIMUM ACTIVE GENERATIONS field through LATEST field in
Figure 30)
3. Validation Parameters (see TYPE field and MASK field in Figure 30)
The groups are separated by a delimiter line.

93
Control-M/Analyzer User Guide

Figure 30 Database Variable Definition Screen


------------------ CONTROL-M/ANALYZER VARIABLE DEFINITION ---------------- BV.S
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
NAME TOTAL_ONHAND GROUP ACCT_INV
CREATED 04/04/00 - 10:00:00 BY M43 TYPE O (B-BATCH,O-ONLINE)
DESC TOTAL ON HAND QUANTITY FOR ACCOUNTING
===========================================================================
MAXIMUM ACTIVE GENERATIONS 0010 GEN TYPE I (I-INDEPENDENT,H-HIERARCHICAL)
CURRENT ACTIVE GENERATIONS 0005
OLDEST -4 DATE 04/04/00
LATEST 0 DATE 08/08/00
===========================================================================
TYPE VAR
MASK

============= >>>>>>>>> BOTTOM OF VARIABLE DEFINITION <<<<<<<<<<< =============

PLEASE FILL IN VARIABLE DEFINITION 12.09.51

94
Control-M/Analyzer User Guide

Basic Parameters
Basic parameters provide basic information about Database variables.
Figure 31 Basic Parameters
+-----------------------------------------------------------------------------+
NAME TOTAL_ONHAND GROUP ACCT_INV
CREATED 04/04/00 - 10:00:00 BY M43 TYPE O (B-BATCH,O-ONLINE)
DESC TOTAL ON HAND QUANTITY FOR ACCOUNTING
===========================================================================

Table 41 Basic Parameters

Parameter Description

NAME Name of the variable. For display only.

GROUP Name of the GROUP to which the variable belongs


(meaning, ACCOUNTING, PAYROLL). The group is determined when
first entering the definition screen. After the definition screen is
entered, this parameter is for display only.

CREATED... Date, time, creator, and type of the variable. The BY subparameter
(the creator of the variable) is determined by Control-M/Analyzer and
BY...TYPE
is for display only. The TYPE subparameter contains the type of
activity that created the variable. Valid TYPE values are:
 O – Variable created by the online facility.
 B – Variable created by batch (see Automatic Database Variable
Creation (on page 235)).

DESC Description of the variable (free text).

95
Control-M/Analyzer User Guide

Generation Parameters
Generation parameters provide information regarding the number of historical values Control-M/Analyzer
stores for a specified Database variable.
Figure 32 Generation Parameters
===========================================================================
MAXIMUM ACTIVE GENERATIONS 0010 GEN TYPE I (I-INDEPENDENT,H-HIERARCHICAL)
CURRENT ACTIVE GENERATIONS 0005
OLDEST -4 DATE 11/11/97
LATEST 0 DATE 06/06/00
===========================================================================

Table 42 Generation Parameters

Parameter Description

MAXIMUM ACTIVE Maximum number of generations (values) of a variable for


GENERATIONS Control-M/Analyzer to track and store. The entry must be numeric,
within a range from 1 through 1000. Mandatory. This parameter can
be changed at any time on the Database Variable Definition screen.

GEN TYPE For future use.

CURRENT ACTIVE Number of generations (values) of this variable currently kept by


GENERATIONS Control-M/Analyzer. For display only.

OLDEST... DATE Generation and creation date of the oldest generation (value) of this
variable. For display only.

LATEST... DATE Generation and creation date of the newest generation (value) of this
variable. For display only.

96
Control-M/Analyzer User Guide

Validation Parameters
Database variable definition specifications will be provided by Validation parameters in future versions.
Figure 33 Validation Parameters
===========================================================================
TYPE VAR
MASK

============= >>>>>>>>> BOTTOM OF VARIABLE DEFINITION <<<<<<<<<<< =============

Table 43 Validation Parameters

Parameter Description

TYPE For future use.

MASK For future use.

Exiting the Database Variable Definition Screen


Use the commands described in Table 44 to exit the Database Variable Definition screen.
Table 44 Database Variable Definition Screen Exit Commands

Command Description

END Keep the changes made to the parameters of the variable and return
to the Variable List screen. Automatic Syntax Checking is performed.
For more information, see Saving a Database Variable Definition (on
page 98).

CANCEL or RESET Do not keep the changes made to the parameters of the variable and
return to the Variable List screen. For more information, see Canceling
Changes (on page 98).

97
Control-M/Analyzer User Guide

Saving a Database Variable Definition


Press END (PF03/PF15) to exit the Database Variable Definition screen. If changes have been made to
the Database variable and no errors are found during Automatic Syntax Checking, an Exit Option window
is opened.
Figure 34 Control-M/Analyzer Variable Definition Exit Option Window
----------------------- Control-M/Analyzer VARIABLE DEFINITION --------------------
COMMAN +-----------------------------------------------------------+ ===> CRSR
+----- | PLEASE SELECT EXIT OPTION | -------+
NAME | |
CREA | SAVE CREATE | ,J-JOB)
DESC | |
==== | VARIABLE TOTAL_ONHAND | =======
MAXI | | CHICAL)
CURR +-----------------------------------------------------------+
OLDEST -4 DATE 11/11/97
LATEST 0 DATE 09/09/99
===========================================================================
TYPE VAR
MASK

============= >>>>>>>>> BOTTOM OF VARIABLE DEFINITION <<<<<<<<<<< =============

PLEASE FILL IN VARIABLE DEFINITION 12.12.00

Enter Y (Yes) or N (No) in one of the exit options (SAVE or CREATE). It is possible to change the name of
the variable in the confirmation window. You then return to the Variable List screen.

Canceling Changes
If you do not want to save the variable definition, press RESET (PF04/PF16) from the Database
Variable Definition screen or RESET from the Exit Option window. As a result, you then return to the
Variable List screen. The Database variable parameters are not saved.

Automatic Syntax Checking


When you exit the Database Variable Definition screen using the END command, Control-M/Analyzer
automatically checks the syntax of the definition.
 If errors are found, you remain in the Database Variable Definition screen and an error message is
displayed. You may then correct the errors.
 If no errors are found, an Exit Option window is displayed.
 If you exit the Database Variable Definition screen by the CANCEL or RESET command, Automatic
Syntax Checking is not performed and the Exit Option window is not displayed.

98
Control-M/Analyzer User Guide

View Graph by Variable Generations Screen


The View Graph by Variable Generations screen graphically displays the status of all generations of a
specific variable in the Control-M/Analyzer Database. The Database contains the current and previous
values of all variables that have been created. On the screen, you can graphically display information
about a single variable.
To display the View Graph by Variable Generations screen, select Option G (Graph) on the List of
Variables screen. Use the scrolling conventions to scroll the View graph forward and backward.
Figure 35 View Graph by Variable Generations Screen
---------------------VIEW GRAPH - BY VARIABLE GENERATIONS -------------(BV.G)
COMMAND ===> SCROLL=== CRSR
SCALE 1 : 2 GROUP INTRAC VARIABLE COST04
GENERATION VALUE +---+---10----+---20----+---30----+---40----+---50
GEN 000 38
GEN 001 12
GEN 002 10
GEN 003 15
GEN 004 24
GEN 005 2
GEN 006 42
GEN 007 33
GEN 008 22
GEN 009 20
GEN 010 15
GEN 011 37
GEN 012 22
GEN 013 25
GEN 014 40
GEN 015 100
GEN 016 15
====== >>>>>>> NO MORE ENTRIES IN THE LIST <<<<<<< ======

COMMANDS: REFRESH (VIEW DATA) END (RETURN TO PREVIOUS SCREEN) 09.33.26

Scale of the Graph


The screen header indicates the scale of the graph. For example, SCALE 1:10 means that each character
position in the graph represents 10. The scale is adjusted automatically so that the largest displayed value
ends near the right margin and zero is near the left margin of the graphic display.
The scale can be modified online by entering the desired scale in the header line. One reason for doing
this is to eliminate the effect of one or more erroneous values that distort the graph. For example, if all
generations of a variable have values between 1 and 500 except a single generation whose value is
10 million, setting the scale to 1:10 produces a meaningful display of all generations except the one
whose value is 10 million.

99
Control-M/Analyzer User Guide

Displayed Information
The name of the Group to which the variable belongs and the name of the variable are displayed in the
screen header.
Table 45 shows the information that is displayed for each generation:
Table 45 View Graph by Variable Generations Screen Information

Field Description

GENERATION Generation number (where 0 is the current generation).

VALUE Numeric value or an asterisk to indicate a character variable.

Graphic value The lines in the graph form a histogram indicating the value of each
generation. The line is replaced by a character string for character
variables.

The variables are displayed in chronological order by generation number. Auto Refresh mode is available
under this screen.

Commands
The View Graph by Variable Generations screen has two commands:
Table 46 Commands of the View Graph by Variable Generations Screens

Command Description

REFRESH Displays updated data on the screen.

END Returns to previously displayed screen.

Database Variable Display Screen


The Database Variable Display screen displays the status of all generations of a specific variable in the
Control-M/Analyzer Database. The Database contains the current and previous values of all variables that
have been created. On the screen, you can view relevant information about a single variable.
To enter the Database Variable Display screen, enter V in the OPT field to the left of the variable name on
the Variable List screen. Use the scrolling conventions to scroll the Variable display screen forward and
backward.
Note: Upon entry to the Database Variable Display screen, the variables are displayed in reverse
chronological order by creation date, the most recent (current) generation being displayed first.

100
Control-M/Analyzer User Guide

Variable Display Types and Fields


For each kind of variable display, a number of predefined display types are available. These predefined
types and the fields they contain are discussed below.
Changing Display Types
You can change the display type by using the DISPLAY command. The format of the command is:
DISPLAY x

where x is the identifying letter for the desired type. DISPLAY can be abbreviated DI.
Example
DISPLAY A

displays the All Fields display type.


Display Type S (Short)
The Short display type is illustrated in Figure 36.
Figure 36 Database Variable Display Type S (Short)
-------<S>-------- GROUP INTRAC VAR INVAMT02 -------(BV.V)
COMMAND ===> SCROLL===> CRSR
O GROUP NAME VARIABLE NAME GENERATION
INTRAC INVAMT02 000
INTRAC INVAMT02 001
INTRAC INVAMT02 002
INTRAC INVAMT02 003
INTRAC INVAMT02 004
INTRAC INVAMT02 005
INTRAC INVAMT02 006
INTRAC INVAMT02 007
========>>>>>>>>>>>>>>>>>>>>>>>> END OF DATA <<<<<<<<<<<<<<<<<<<<<<==========

Fields in the Short Display Type


Table 47 Fields of the Variable Display Type (S)

Field Description

O Option to be activated on the Database variable. Option D (delete) is


available. Options A (additional info) and U (update) are not
applicable to this display type.

GROUP NAME Group name of the variable. For more information, see GROUP Basic
Parameters (on page 240).

VARIABLE NAME Variable name. For more information, see NAME Basic Parameters (on
page 239).

GENERATION Identifier of each (previous or current) value of the variable.


*** indicates a deleted generation.

101
Control-M/Analyzer User Guide

Display Type I (Info)


The Info display type is illustrated in Figure 37.
Figure 37 Database Variable Display Type I (Info)
-------<I>-------- GROUP ACCT_INV VAR TOTAL_ONHAND --------(BV.V)
COMMAND ===> SCROLL===> CRSR
O GROUP NAME VARIABLE NAME GEN DATE TIME BY USER RULE
ACCT_INV TOTAL_ONHAND 000 04/04/00 13:28 M43 RULEWV
==> 500 <==
-------------------------------------------------------------------------------
ACCT_INV TOTAL_ONHAND 001 04/04/00 13:27 M43 RULEWV
==> 475 <==
-------------------------------------------------------------------------------
ACCT_INV TOTAL_ONHAND 002 04/04/00 13:27 M43 RULEWV
==> 485 <==
-------------------------------------------------------------------------------
ACCT_INV TOTAL_ONHAND 002 04/04/00 13:27 M43 RULEWV
==> 505 <==
-------------------------------------------------------------------------------
========>>>>>>>>>>>>>>>>>>>>>>>> END OF DATA <<<<<<<<<<<<<<<<<<<<<===========

OPTIONS: U UPDATE D DELETE 14.31.16


Fields in the Info Display Type

Table 48 Fields of the Variable Display Type I (Info)

Field Description

O Option to be activated on the Database variable. Option D is


available. Options U and A are not available for this display type.

GROUP NAME Group name of the variable (see GROUP Database variable
parameter).

VARIABLE NAME Variable name (see the NAME Database variable parameter).

GEN Identifier of each (previous or current) value of the variable. ***


indicates a deleted generation.

DATE Date the variable was created.

TIME Time the variable was created.

BY USER User ID of user who created the variable.

==>value<== Value of the variable.

RULE Name of the rule that committed the Database variable.

102
Control-M/Analyzer User Guide

Display Type G (General)


Display Type G, the default display type, is illustrated in Figure 38.
Figure 38 Database Variable Display Type G (General)
-------<G>-------- GROUP ACCT_INV VAR TOTAL_ONHAND --------(BV.V)
COMMAND ===> SCROLL===> CRSR
O GROUP NAME --------- VARIABLE NAME ------ GENERATION ------------------------
ACCT_INV TOTAL_ONHAND 000
Value : 500
User Key : FORECAST1 Run Id : TEST3
Creation Date : 06/06/00 13:28:51 By User : M43 Type : O
-------------------------------------------------------------------------------
ACCT_INV TOTAL_ONHAND 001
Value : 475
User Key : FORECAST2 Run Id : TEST2
Creation Date : 06/06/00 13:27:07 By User : M43 Type : O
-------------------------------------------------------------------------------
ACCT_INV TOTAL_ONHAND 002
Value : 485
User Key : FORECAST0 Run Id : TEST2
Creation Date : 06/06/00 13:27:06 By User : M43 Type : O
-------------------------------------------------------------------------------
========>>>>>>>>>>>>>>>>>>>>>>>> END OF DATA <<<<<<<<<<<<<<<<<<<<<===========

OPTIONS: U UPDATE D DELETE 15.10.16

Fields in the General Display Type


Table 49 Fields of the Variable Display Type G (General)

Field Description

O Option to be activated on the Database variable. Available options


are U (Update) and D (delete).

GROUP NAME Group name of the variable (see the GROUP Database variable
parameter).

VARIABLE NAME Variable name (see the NAME Database variable parameter).

GENERATION Identifier of each (previous or current) value of the variable.


*** indicates a deleted generation.

VALUE Value of the variable.

USER KEY User-defined variable identifier.

RUN ID Site-defined run cycle identifier.

CREATION DATE Date and time the variable was created.

BY USER User ID of user who created the variable.

103
Control-M/Analyzer User Guide

Field Description

TYPE Type of activity that created or changed the variable (for


example, B = Batch, O = Online).

Display Type A (All Fields)


The All Fields display type is illustrated in Figure 39.
Figure 39 Fields of the Variable Display Type A (All Fields)
-------<A>-------- GROUP INTRAC VAR ROL1 -------(BV.V)
COMMAND ===> SCROLL===> CRSR
O GROUP NAME VARIABLE NAME GENERATION
INTRAC INVAMT02 000
User Key: Cycle Id: 960514134521
Creation Date 08/08/00 11:16:24 Creating User N52 User Type B
Variable: 005 7.000

INTRAC INVAMTO2 001


User Key: Cycle Id:
Creation Date 08/08/00 10:33:30 Creating User N52 User Type B
Variable: 005 6.000

OPTIONS: U UPDATE D DELETE 16.37.15

Fields in the All Fields Display Type


Table 50 Fields of the Variable Display Type A (All)

Field Description

O Option to be activated on the Database variable. Available options


are
 U (update)
 D (delete)
 A (additional information)

GROUP NAME Group name of the variable (see the GROUP Database variable
parameter).

VARIABLE NAME Variable name (see the NAME Database variable parameter).

GENERATION Identifier of each (previous or current) value of the variable.


*** indicates a deleted generation.

104
Control-M/Analyzer User Guide

Field Description

User Key User-defined variable identifier.

Cycle Id Site-defined run cycle identifier. The value can be a timestamp.

Creation Date Date and time the variable was created.

Creating User User ID of user who created the variable.

User Type Type of activity that created or changed this generation of the
variable (for example, B=Batch, O=Online).

Variable The 3-digit length of the current value of the variable is followed by
a blank and the current value (content) of the variable. The value of
the variable can be changed online. The length of the value of the
variable is adjusted automatically.

The bolded fields in Figure 40 are displayed when option A (additional information) is specified:
Figure 40 Variable Display Type A (All Fields) – Additional Information (Option A)
-------<A>-------- GROUP INTRAC VAR INVAMT02 -------(BV.V)
COMMAND ===> SCROLL===> CRSR
O GROUP NAME VARIABLE NAME GENERATION
INTRAC INVAMT02 000
User Key: Cycle Id:
Creation Date 12/29/99 18:54:46 Creating User M66 User Type B
Variable: 010 679025.520

Rolling Back Info:


Date: 06/06/00 15:22:19 User SALLY User Type O
Updating Info:
Date: User User Type
INTRAC INVAMT02 001
User Key: Cycle Id:
Creation Date 12/29/99 18:53:37 Creating User m66 User Type b
Variable: 006 589453
Rolling Back Info:
Date: User User Type
Updating Info:
Date: User User Type
INTRAC INVAMT02 002
USER KEY: Cycle Id:

OPTIONS: U UPDATE D DELETE 13.03.36

105
Control-M/Analyzer User Guide

Table 51 Fields of the Variable Display Type A (All Fields) – Additional Information
(Option A)

Field Description

Date Date and time the variable was rolled back or updated.

User User ID of the user who rolled back or updated the variable.

User Type Type of activity that created or changed this generation of the
variable (for example, B=Batch, O=Online).

Options of the Database Variable Display Screen


To apply one of the options described in Table 52 to an individual variable, specify the option in the OPT
(option) field to the left of the variable and press Enter.
Table 52 Options of the Database Variable Display Screen

Option Description

U (UPDATE) Updates the variable with changes made to non-protected


(updatable) fields. Not available for read-only Display Type I (Info).

D (DELETE) "Deletes" the variable. The variable continues to be displayed in the


Variable list, but cannot be accessed by Control-M/Analyzer rules.
The "deletion" is indicated by three asterisks *** in the variable
generation field of the display. Not available for read-only Display
Type I (Info).

Commands of the Database Variable Display Screen


INSERT Command
This command enables the user to manually insert a new current generation of a Database variable. The
generation number of existing generations, if any, is automatically incremented by one. The user must set
the value, and optionally can set the User Key and Run ID of the inserted current generation.
Automatically, the Creation Date is set to the current date and time, the By User field is set to the user’s
User ID, and the Type field is set to O (indicating that this generation was created by the online facility).
The INSERT command, or the abbreviation I, is typed on the command line of the Database Variable
Display screen. When Enter is pressed, an empty variable generation record is displayed at the top of the
screen. The message "PLEASE FILL IN THE ENTRY DATA" is also displayed. After specifying the value
and, optionally, the User Key and Run ID fields, press Enter to insert the generation in the Database. The
message "ENTRY ADDED" is displayed.

106
Control-M/Analyzer User Guide

Rule Definition Facility


The Control-M/Analyzer Rule Definition facility is composed of a series of screens that enable you to view,
create and modify rule definitions and parameters.
Rules are the main Control-M/Analyzer entities that manage media at your site. A rule is a user-defined
list of instructions (parameters) whose execution is automatically triggered when specified media are
accessed. Real-time media management processes and maintenance procedures can be tailored to meet
your local site needs through rule definitions.

Rule Definition
Rule parameters under Control-M/Analyzer are stored in libraries (partitioned data sets). Each member of
the library contains one rule and balancing criteria related to a specific topic. Although most sites
designate a primary rule definition library, the number of permitted rule definition libraries is unlimited.
Note: The number of rules (members) in a library and the size of each rule are all calculated dynamically
and are not dependent on parameter specification.

Screens of the Rule Definition Facility


The Rule Definition facility contains the screens described in Table 53.
Table 53 Rule Definition Facility Screens

Screen Description

Rule Definition Facility Allows specification of parameters that determine which screen is
entry panel displayed.

Rule List screen Displays the list of rules in the selected table.

Rule Definition screen Displays the parameters of the selected rule definition. This is the
main screen of the facility.

To enter the Rule Definition facility, select Option BR on the IOA Primary Option menu. The Rule
Definition entry panel is displayed.

107
Control-M/Analyzer User Guide

Entry Panel
Figure 41 Rule Definition Facility – Entry Panel
------------------- CONTROL-M/ANALYZER RULE DEFINITION - ENTRY PANEL -----------(BR)
COMMAND ===>

SPECIFY LIBRARY, RULE

LIBRARY ===> CTB.PROD.RULES


RULE ===> (Blank for rule selection list)

USE THE COMMAND "SHPF" TO SEE PFK ASSIGNMENT 13.59.53

Note: If you use the selection list fields, their values are not erased until you exit the entry panel by
pressing END (PF03/PF15).
 To display the list of rules in a library, do the following:
1. Type the library name.
2. Leave the rule name blank or type part of the rule name using mask characters (* and ?).
3. Press Enter.

 To display the details of a specific rule, do the following:


4. Type the library name.
5. Type the rule name.
6. Press Enter.
If the rule is not in the library, the screen for defining a new rule is displayed.

108
Control-M/Analyzer User Guide

Rule List Screen


The Rule List screen displays the list of rules in a specified library. You can enter this screen directly from
the Rule Definition entry panel or when exiting from the Rule Definition screen.
By default, only member names are listed in the screen. However, if the default has been modified,
statistical information is displayed for each member name (as illustrated in Figure 42.
Figure 42 Rule Definition Facility Rule List Screen
LIST OF RULES IN CTB.PROD.RULES ------------(BR)
COMMAND ===> SCROLL===> CRSR
OPT NAME ------------ VV.MM CREATED CHANGED SIZE INIT MOD ID
CMPRUN1 01.14 99/09/10 99/12/29 08:46 31 18 0 M66
CMPRUN3 01 13 99/09/10 99/12/29 08:55 4 34 0 M27A
DAB1A0 01 14 99/09/10 99/12/29 08:56 4 46 0 M66
DAB1AS 01 12 99/09/10 99/12/29 09:01 4 46 0 M66
DAB1AT 01 11 99/09/10 99/12/29 09:15 2 17 0 M55A
DAB2A0 01.11 99/09/10 00/06/06 14:40 78 49 0 M66
DAB2AS 01.14 99/08/05 99/12/16 14:24 97 46 0 M66
DFH 01.15 99/09/03 99/12/29 19:44 122 17 0 M55A
IMS 01.09 99/11/26 00/06/06 15:42 24 24 0 M32A
ICH 01.01 99/12/08 00/08/08 10:55 7 7 0 M32A
IEE 01.12 99/06/16 00/04/04 14:16 32 20 0 M55A
IEF 01.11 99/08/10 00/10/10 14:34 213 100 0 M55A
IOS 01.10 99/07/22 00/09/14 14:34 30 26 0 M55A
IPL 01.04 99/06/15 00/00/10 14:35 24 21 0 M55A
JES 01.08 99/06/15 00/04/04 14:35 19 16 0 M55A
JOB 01.13 99/07/09 00/09/14 14:36 18 16 0 M55A
RFPFIG01 01.12 99/06/10 00/08/08 14:38 16 14 0 M55A
RFPFIG02 01.14 99/06/10 00/04/04 14:38 16 20 0 M55A
RULFILE1 01.10 99/07/09 00/10/10 14:38 13 8 0 M55A
RULFILE2 01.00 99/11/09 00/08/08 15:22 14 14 0 M18
OPTIONS: S SELECT B BROWSE D DELETE I INSERT N NEW 18.10.29

To scroll down the Table list, press PF08/PF20. To scroll up the Table list, press PF07/PF19.
To return to the entry panel, press END (PF03/PF15).

Options of the Rule List Screen


To use one of the options described in Table 54, type the option in the OPT field to the left of the rule
name and press Enter:
Table 54 Options of the Rule List Screen

Option Description

S (SELECT) Display the Rule Definition screen with details of the specific rule.
Note: If the S (Select) option is specified in the Rule List screen for
a rule that is currently in use (selected) by another user, then the
Rule Definition screen is not displayed and the Rule List screen
remains displayed (the default), or the rule definition is displayed in
Browse mode (if a User Profile definition overrides the default). In
either case, an appropriate message is displayed.

109
Control-M/Analyzer User Guide

Option Description

B (BROWSE) Display rules for browsing. Only one rule may be selected at a time.
Note: If the Rule List screen is displayed in Browse mode, options
D (Delete), I (Insert) and N (New) are not available.

D (DELETE) Delete a rule (member) from the Rule List. Multiple rules may be
selected.

I (INSERT) Copy an existing rule definition into a newly created list. The Rule
Definition screen appears, with the same details as the rule marked
"I", but the RULE parameter is empty for you to fill in. The new rule
is added to the list in alphabetical order.

N (NEW) Insert a new rule in the list. An empty Rule Definition screen is
displayed for you to fill in. The new rule is added to the list in
alphabetical order.

Deleting Rules
To delete rules, type D in the OPT field to the left of the rule names and press Enter.
The confirmation window illustrated in Figure 43 is displayed, in sequence, for each rule selected for
deletion:
Figure 43 Rule Definition Facility Delete Rule Confirmation Window
LIST OF RULES IN CTB.PROD.RULES -------------(BR)
COMMAND ===> SCROLL===> CRSR
OPT NAME ------------ VV.MM CREATED CHANGED SIZE INIT MOD ID
ARSETVAR 01.14 98/09/10 00/04/04 08:46 31 18 0 M66
ARWARN01 +--------------------------+ 4 34 0 M27A
ARWARN02 | CONFIRM DELETE OPTION | 4 46 0 M66
D ARWARN03 <-----------| (Y/N) | 4 46 0 M66
ARWARN04 +--------------------------+ 2 17 0 M55A
ARWARN05 01.11 98/09/10 00/06/06 14:40 78 49 0 M66
ARWARN06 01.14 98/08/05 99/11/18 14:24 97 46 0 M66
ARWARN4A 01.15 98/09/03 99/12/29 19:44 122 17 0 M55A
ARWARN4B 01.09 98/11/26 99/12/29 15:42 24 24 0 M32A
ARWARN4C 01.01 98/12/08 00/02/08 10:55 7 7 0 M32A
RULAE 01.12 98/06/16 99/12/23 14:16 32 20 0 M55A
RULALL 01.11 98/09/10 99/12/23 14:34 213 100 0 M55A
RULBLL 01.10 98/07/22 00/08/08 14:34 30 26 0 M55A
RULCALLB 01.04 98/06/15 00/10/10 14:35 24 21 0 M55A
RULCALLR 01.08 98/06/15 00/10/10 14:35 19 16 0 M55A
RULCDM 01.13 98/07/09 00/10/10 14:36 18 16 0 M55A
RULCLASS 01.12 98/06/10 00/08/08 14:38 16 14 0 M55A
RULCOMIT 01.14 98/06/10 00/06/06 14:38 16 20 0 M55A
RULCOND 01.10 98/07/09 00/08/08 14:38 13 8 0 M55A
RULCTM 01.00 99/11/19 99/12/29 15:22 14 14 0 M18
OPTIONS: S SELECT B BROWSE D DELETE I INSERT N NEW 18.10.29

Enter Y (Yes) in the confirmation window to delete the rule.


Enter N (No) to cancel the deletion request.

110
Control-M/Analyzer User Guide

Note: If PDSMAN is operational at your site, $$$SPACE members cannot be deleted.


For each rule deleted, a message is written to the IOA Log file.

Rule Definition Screen


The Rule Definition screen is used to define, display, and modify parameters of a specific rule. This screen
can be entered directly from the entry panel or from the Rule List screen.
Rule parameters can fill more than one screen. Therefore, they are organized as a sheet of paper that can
be "stretched" to any desired length. Use the scrolling conventions to scroll the rule parameters forward
and backward.
Figure 44 Rule Definition Screen
LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M43 GROUP ACCT_INV
UPDATED 07/07/00 - 15:25:54 BY M43
DESC REORDER INVENTORY ITEM CHR001 IF NECESSARY
OPTIONS
===========================================================================
EXECUTE SETUP UPON C
ON DATA
ALWAYS
DO SET = MIN_CHR001=100 C
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE CHECK UPON C
ON SYSOUT PROCST PGMST DDNAME INVENTRY JOBNM
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = CHR001
DO EXTRACT = CURR_ONHAND
LEVEL 0 LINE +000 COL +050 - +060 PROCESS TYP
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE COMPARE UPON C
ON DATA
ALWAYS
DO SET = DIFFER=ABS(CURR_ONHAND-MIN_CHR001) C
DO SET = REASON=TOLER(CURR_ONHAND,MIN_CHR001,10) C
DO
IF CURR_ONHAND>=MIN_CHR001 C
DO PRINT = DO NOT REORDER; SURPLUS=%%DIFFER F C
DO
ELSE
DO PRINT = REORDER; DEFICIT=%%DIFFER F C
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
====== >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====
PLEASE FILL IN RULE DEFINITION. 16.33.11

Rule parameters are divided into the following basic groups:


1. General Rule parameters (OWNER, GROUP, DESC, and so on)
2. Selection statements (ON)
3. Data Identification parameters (WHEN, IF, ELSE, ALWAYS)

111
Control-M/Analyzer User Guide

4. Automated Balancing Action statements (DO)


One ON statement, an associated Data Identification parameter, and one or more DO statements
constitute an EXECUTE block.
EXECUTE blocks are separated by a delimiter line (=====).
Each rule is composed of Basic Rule parameters, followed by one or more blocks of statements. In
Control-M/Analyzer, a block of statements beginning with EXECUTE is called an EXECUTE block. These
blocks are composed of data specifications, rule processing instructions and calculations, and actions that
are performed as a result of the rule. The execute blocks in the screen examples are separated by
separator (delimiting) lines (E). For more information about the EXECUTE block structure, see EXECUTE
Block Structure Overview (on page 351).
For a detailed explanation of the rule parameters, see Rule Definition (on page 348).
Note: Parameters marked with the symbol M can have many occurrences. Whenever you fill in the last
occurrence of the parameter on the screen, Control-M/Analyzer adds a new empty occurrence of that
parameter that you may fill in. The only limit to the number of occurrences is the region size available for
the application.
To delete a parameter on the screen, erase it by pressing the EOF key or blanking it out. If additional
action is required, Control-M/Analyzer issues appropriate instructions.
The Rule Definition screen can also be edited using ISPF-like editing commands (such as copy, move,
repeat, after, and before) in the Control-M/Analyzer Edit environment. For additional information about
the Control-M/Analyzer Edit environment, see A Editing Rule Definitions in the IOA Edit Environment (on
page 660).
The rule definition is automatically saved to a PDS member that can be edited using a standard editor
such as the ISPF Edit facility. Rules originally defined using a standard editor can be displayed and edited
in the Rule Definition screen. For additional information on creating and editing rule definitions by a
standard editor see Rule Definition (on page 348).

112
Control-M/Analyzer User Guide

General Rule Parameters


General rule parameters provide basic information about the rule.
Figure 45 General Rule Parameters
+-----------------------------------------------------------------------------+
OWNER M43 GROUP ACCT_INV
UPDATED 07/07/00 - 15:25:54 BY M43
DESC REORDER INVENTORY ITEM CHR001 IF NECESSARY
OPTIONS

===========================================================================

Table 55 General Rule Parameters

Parameter Description

OWNER User ID of the owner of the rule.

GROUP Group to which the rule is assigned.

Note: If the OWNER or GROUP parameter is specified in the mission definition, it overrides
the corresponding parameter in the rule definition specified here.

UPDATED... BY Date and time of last update... last user to update the rule.

DESC Description of the rule (free text).

OPTIONS For future use.

113
Control-M/Analyzer User Guide

Selection Parameters
Selection parameters determine the data source type the rule should examine and balance. These
parameters also control which EXECUTE blocks within a rule are processed.
Figure 46 Selection Parameters
EXECUTE CHECK1 UPON C
ON FILE FILENAME INVENT
MODE PG LINECT 0060 DATASTAMP

EXECUTE CHECK2 UPON C


ON SYSOUT PROCST PGMST DDNAME INVENTRY JOBNM

MODE PG LINECT 0060 DATASTAMP

EXECUTE SETUP UPON C


ON DATA

Table 56 Selection Parameters

Parameter Description

EXECUTE Specifies the name for the EXECUTE block. The name should be unique
within the rule.

ON data-type Objects on which balancing is to be performed, including:

 ON CLASS – Outputs of the job.

 ON COMPARE – Compares two data sources.

 ON DATA – Control-M/Analyzer variables.

 ON DB2 – Data from DB2 tables.

 ON DDNAME – Files referenced by DD statement in the current step.

 ON DSN – For Control-D users: A Compressed Data set Access method


(CDAM) file. CDAM file selection criteria can be specified.

 ON FILE – Sequential data set

 ON PAGE – For Control-D users: Pages passed to Control-M/Analyzer


from Control-D.

 ON SYSDATA – For Control-M and Control-M/Restart users: The three


job sysout data sets, referred to as SYSDATA, that are passed to
Control-M/Analyzer from Control-M.

Note: SYSDATA is an IOA term used to refer to the following three job
sysout data sets: job log (console messages), expanded JCL, and system
output messages.

 ON SYSOUT – Outputs of the current job. Outputs of previous steps


and jobs can be specified.

 ON VSAM – VSAM file identifier.

114
Control-M/Analyzer User Guide

Data Identification Parameters


The Data Identification parameters specify the actual criteria (character strings and values) that
Control-M/Analyzer should examine within the data source specified by the ON statement.
Figure 47 Data Identification Parameters
WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = CHR001
DO EXTRACT = CURR_ONHAND
LEVEL 0 LINE +000 COL +050 - +060 PROCESS TYP
ON DATA
LABEL:
ALWAYS
DO SET = DIFFER=ABS(CURR_ONHAND-MIN_CHR001) C
DO SET = REASON=TOLER(CURR_ONHAND,MIN_CHR001,10) C
DO

LABEL:
IF CURR_ONHAND>=MIN_CHR001 C
DO PRINT = DO NOT REORDER; SURPLUS=%%DIFFER F C

DO
ELSE
DO PRINT = REORDER; DEFICIT=%%DIFFER F C

DO
(ENTER "ALWAYS", "IF")

Table 57 Data Identification Parameters

Parameter Description

WHEN Available for all ON statements (except ON DATA).


Control-M/Analyzer searches the file, line by line, for the specified
character string in the specified range. If the string is found (before
the STOP string is found), the DO statements in the WHEN block are
processed. For more information seeWHEN: Rule Definition
Structure (on page 488).

STOP Yes/No flag that indicates if STOP criteria are to be specified. The
format of STOP criteria subparameters is identical to that of WHEN
subparameters.

ALWAYS Available when ON DATA is specified. ALWAYS specifies a group of


DO statements that should be executed under all conditions.

IF condition Available when ON DATA is specified. Boolean conditional


expressions determine if the next group of DO statements is
processed.

ELSE condition If the specified condition resolves to false, the DO statements


following ELSE are processed. If the specified condition resolves to
true, the DO statements following ELSE are skipped.

115
Control-M/Analyzer User Guide

Automated Balancing Action Statements: DO Statement


The Automated Balancing Action statements of Control-M/Analyzer permit the specification of processing
instructions and post-processing actions during rule execution.
These actions are specified by DO statements. The DO statement specifies an action to be taken. An
unlimited number of DO statements are permitted.
To specify Automated Balancing Action statements, type the action keyword next to DO on the Rule
Definition screen and press Enter. Depending on the specified action, different subparameters are
displayed on the screen.
Note: It is usually not necessary to enter the full action keyword; the shortest unique abbreviation is
sufficient.
DOM Options
The following are a description and example of each of the DO statement options.
DO ADDSYM – Adds an AutoEdit variable to an AutoEdit member that has been read (using statement
DO GETMEM).
WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = CHR001
DO ADDSYM = CHR001 MEM CHRSYM
LIBSYM CTB.PROD.SYMBOLS
DO

DO BLOCK – Processes another EXECUTE block within the current rule (as long as the EXECUTE criteria
of the called block are met).
WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = CHR001
DO BLOCK = NEXTBLOC ARG C
DO

DO CALLUSER – Calls a user routine.


WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = CHR001
DO CALLUSER = COMP001 ARG C
DO

DO COMMIT – Determines the method by which Database variables are committed (written) to the
Database.
WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = CHR001
DO COMMIT = ALL VAR C
DO

DO COND – Adds or deletes prerequisite conditions.


WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = CHR001
DO COND = ACCT_BALANCE_OK ODAT +
DO

116
Control-M/Analyzer User Guide

DO EXIT – Immediately terminates the current block. Control passes to the statement that called the
block, if there is one.
WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = END OF DATA
DO EXIT
DO

DO EXTRACT – Available when ON DATA is not specified. Assigns a value to a variable. The value is
extracted from the current data source.
WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = CHR001
DO EXTRACT = CURR_ONHAND
LEVEL 0 LINE +000 COL +050 - +060 PROCESS TYP
DO

DO GETMEM – Reads (accesses) an AutoEdit member, enabling the use of its AutoEdit symbols for
AutoEdit substitution and variable setting.
WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = CHR001
DO GETMEM = CHRSYM
LIBSYM CTB.PROD.SYMBOLS
DO

DO GOTO – Processes the IF or ALWAYS parameter in the current ON DATA block whose label matches
the specified LABEL name.
WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = CHR001
DO GOTO LABEL NEXTLOOP
DO

DO PRINT – Prints the specified data string to the Control-M/Analyzer default output DD statement and
to the Control-M/Analyzer Rule Activity report.
LABEL:
IF CURR_ONHAND>=MIN_CHR001 C
DO PRINT = DO NOT REORDER; SURPLUS=%%DIFFER F C
DO
DO PRINT

DO PUTMEM – Writes a member back to the library for future use by Control-M/Analyzer or other
INCONTROL products.
WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = CHR001
DO PUTMEM = CHRMEM
LIBSYM CTB.PROD.SYMBOLS
DO

DO REMARK – Adds a user-defined remark to the Rule Activity report, which summarizes the
Control-M/Analyzer invocation.
WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = CHR001
DO REMARK = RULE CALCULATIONS HAVE BEEN COMPUTED SUCCESSFULLY
DO

117
Control-M/Analyzer User Guide

DO RULE – Invokes another rule from within the current rule.


WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = CHR001
DO RULE = RULE1 ARG C
DO

DO SET – Assigns a value to a Database, AutoEdit, or Local variable.


LABEL:
ALWAYS
DO SET = DIFFER=ABS(CURR_ONHAND-MIN_CHR001) C
DO SET = REASON=TOLER(CURR_ONHAND,MIN_CHR001,10) C
DO

DO SHOUT – Sends a message to a specified destination when the identifying string in the WHEN
statement is found.
WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = CHR001
DO SHOUT TO TSO-M43 URGENCY R
= INVENTORY MUST BE REORDERED AT 17:00
DO

DO TERMINAT – Requests rule termination and determines the status of the rule by defining termination
codes. The rule is terminated after this statement.
WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = CHR001
DO TERMINAT = TOLER COD 0001
DO

118
Control-M/Analyzer User Guide

Specifying Comments
Comments are free text descriptions of rule definition parameters that are stored in a rule definition
member. BMC recommends that comments be inserted within rule definitions for clarification and
documentation. Comments are not processed during rule execution.
To insert a comment, position the cursor at the line before which the comment should be inserted and
press CMNT (PF04/PF16). A comment line is opened beginning with the symbol /*. To insert additional
lines, fill in the current line and press Enter.
Note: Comments can also be inserted by typing the CMNT command in the COMMAND field, moving the
cursor to the line before which the comment should be inserted, and pressing Enter.
The Rule Definition screen illustrated in Figure 48 illustrates comment usage:
Figure 48 Illustration of Rule Definition Comment Usage
LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M43 GROUP ACCT_INV
UPDATED 07/07/00 - 15:25:54 BY M43
DESC REORDER INVENTORY ITEM CHR001 IF NECESSARY
OPTIONS
===========================================================================
/* INITIALIZATION OF THE MINIMUM AMOUNT REQUIRED ON-HAND FOR
/* INVENTORY ITEM CHR001.
EXECUTE SETUP UPON C
ON DATA
ALWAYS
DO SET = MIN_CHR001=100 C
DO
(ENTER "ALWAYS", "IF")
===========================================================================
/* DETERMINE CURRENT ON-HAND QUANTITY OF INVENTORY ITEM CHR001 BY
/* EXTRACTING THIS VALUE FROM SYSOUT DDNAME INVENTRY.
EXECUTE CHECK UPON C
ON SYSOUT PROCST PGMST DDNAME INVENTRY JOBNM
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
PLEASE FILL IN RULE DEFINITION. 08.47.46

An unlimited number of comment lines may be specified within a rule definition.

119
Control-M/Analyzer User Guide

Editing Rule Definitions in the Edit Environment


A 2-character line editing command field, marked by underscores, is displayed for each line on the Rule
Definition screen. Editing commands are typed directly onto these underscores. Rule Definition
parameters can be edited (moved, copied, deleted, repeated) by performing line editing commands,
similar to standard ISPF line commands, from within the Control-M/Analyzer Edit environment.
The Edit environment of the Rule Definition screen is accessed by typing EDIT in the COMMAND field of a
definition screen and pressing Enter.
Figure 49 Entering Editing Command
LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
__ /* COMPARE THE CURRENT ON-HAND AMOUNT (DATABASE VARIABLE
__ /* CURR_ONHAND) TO THE MINIMUM REQUIRED AMOUNT (DATABASE VARIABLE
__ /* MIN_CHR001). DETERMINE IF REORDERING IS NECESSARY, AND PRINT A
__ /* MESSAGE INDICATING THE RESULTS
__ EXECUTE COMPARE UPON C
__ ON DATA
__ ALWAYS
MM DO SET = DIFFER=CURR_ONHAND-MIN_CHR001 C
MM DO SET = REASON=TOLER(CURR_ONHAND,MIN_CHR001,10) C
__ DO
__ IF CURR_ONHAND>=MIN_CHR001 C
B_ DO PRINT = DO NOT REORDER; SURPLUS=%%DIFFER F C
__ DO
__ ELSE
__ DO PRINT = REORDER; DEFICIT=%%DIFFER F C
__ DO
__ (ENTER "ALWAYS", "IF")
__ ===========================================================================
__ EXECUTE UPON C
__ ON
PLEASE FILL IN RULE DEFINITION. 09.02.21

A 2-character line editing command field, marked by underscores, is displayed for each line on the Rule
Definition screen. Editing commands are typed directly onto these underscores.
Incorrectly specified line editing commands can be corrected by typing over them correctly. Line editing
commands can be deleted by blanking them out or by specifying the RESET command in the COMMAND
field.
Specified line editing commands are processed when Enter is pressed.
For additional information about and examples, see A Editing Rule Definitions in the IOA Edit
Environment (on page 660).

120
Control-M/Analyzer User Guide

Commands of the Rule Definition Screen


Table 58 Commands of the Rule Definition Screen

Command Description

EDIT The EDIT command alternately enters and exits the Edit
environment of the Rule Definition screen. The Edit environment
provides ISPF-like line editing commands for the Rule Definition
screen. For more information see A Editing Rule Definitions in the
IOA Edit Environment (on page 660).

CMNT The CMNT command (PF04/PF16) inserts comment lines after the
current line. To insert a comment, type CMNT in the COMMAND
field, position the cursor on the line before which comments should
be inserted, and press Enter. For more information see Specifying
Comments (on page 119).

LABEL The LABEL command alternately displays and hides the (empty)
labels of ALWAYS and IF subparameters. These labels are used as
rule processing flow reference points by statement DO GOTO.

The Rule Definition screen in Figure 50 contains a LABEL specification (RULE_END).


Figure 50 Rule Definition Screen with the LABEL Specification
LIBRARY : CTB.PROD.RULES RULE : COMMIT1
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
EXECUTE COMMIT UPON C
ON DATA
LABEL: RULE_END
IF DB_CURRENCY.SUM > 50000.00 C
DO SHOUT TO U-M18 URGENCY R
= PLEASE CHECK CURRENCY FILE; PROBLEMS WITH SUM
DO REMARK = SUM IS OVER 50000
DO COMMIT = NONE VAR C
DO TERMINAT = NOTOK COD 0055
DO
ELSE
DO REMARK = SUM IS NOT OVER 50000
DO TERMINAT = OK COD 0000
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 15.22.09

121
Control-M/Analyzer User Guide

Exiting the Rule Definition Facility


To exit the Rule Definition facility, the screens described in Table 59 must be exited in sequence:
Table 59 Screens for Exiting the Rule Definition Facility

Screen Description

Rule Definition screen How you exit this screen depends on whether changes made in the
Rule Definition screen should be saved. For more information, see
Exiting the Rule Definition Screen (on page 122).

Rule List screen How you exit this screen depends on whether changes made to
each rule should be saved. For more information, see Exiting the
Rule Definition Screen (on page 122).

Entry panel Exit this screen by pressing END (PF03/PF15).

Exiting the Rule Definition Screen


Use the commands described in Table 60 to exit the Rule Definition screen:
Table 60 Commands for Exiting the Rule Definition Screen

Command Description

END Keep the changes made to the parameters of the rule and return to
the Rule list. Automatic syntax checking is performed. For more
information, see Saving a Rule Definition (on page 123).

CANCEL Do not keep the changes made to the parameters of the rule and
return to the Rule list. For more information, see Canceling Changes
(on page 123).

122
Control-M/Analyzer User Guide

Saving a Rule Definition


Press END (PF03/PF15) to exit the Rule Definition screen. If changes have been made in the Rule
Definition facility (and no errors were found during automatic syntax checking), an Exit Option window is
opened.
Figure 51 Rule Definition Screen Exit Option Window
LIST OF RULES IN CTB.PROD.RULES ------------(BR)
= COMMAN +----------------------------------------------------------+ ==> CRSR
= OPT N | PLEASE SELECT EXIT OPTION | ID
= A | | IOAPROD
= A | SAVE Y CREATE | IOAPROD
= A | | IOAPROD
= A | LIBRARY CTB.PROD.RULES | IOAPROD
= A | RULE RULBLL | IOAPROD
= A | | IOAPROD
= A +---------------------------------------------------------+ IOAPROD
= A IOAPROD
= RULAE 01.00 00/08/08 00/08/08 05:00 28 28 0 IOAPROD
= S RULBLL 01.00 00/08/08 00/08/08 05:00 30 30 0 IOAPROD
= RULCALLB 01.00 00/02808 00/08/08 05:00 21 21 IOAPROD
= RULCALLR 01.00 00/08/08 00/08/08 05:00 16 16 0 IOAPROD
= RULCDM 01.00 00/08/08 00/08/08 05:00 19 19 0 IOAPROD
= RULCLASS 01.00 00/08/08 00/08/08 05:00 17 17 0 IOAPROD
= RULCOMIT 01.00 00/08/08 00/08/08 05:00 15 15 0 IOAPROD
= RULCOND 01.00 00/18/08 00/08/08 05:00 14 14 0 IOAPROD
= RULCURR 01.00 00/08/08 00/08/08 05:00 22 2 0 IOAPROD
= RULDSN 01.00 00/08/08 00/08/08 05:00 17 7 0 IOAPROD
= RULEMP 01.00 00/08/08 00/08/08 05:00 38 38 0 IOAPROD
= RULEXT 01.00 00/08/08 00/08/08 05:00 16 16 0 IOAPROD
= OPTIONS: S SELECT B BROWSE D DELETE I INSERT N NEW 13.53.45

You must enter Y (Yes) or N (No) in one of the exit options (SAVE or CREATE). You can change the name
of the library or the name of the rule in the window. You then return to the entry panel.

Canceling Changes
If you do not want to save the rule definition, press RESET from the Rule Definition screen or press
RESET from within the Exit Option window. As a result, you return to the Rule List screen and the rule
parameters are not saved.

Automatic Syntax Checking


When you exit the Rule Definition screen using the END command, Control-M/Analyzer automatically
checks the syntax of the definition.
 If errors are found, you remain in the Rule Definition screen and an error message is displayed. You
may then correct the errors.
 If no errors are found, an Exit Option window is displayed.
 If you exit the Rule Definition screen using the CANCEL or RESET command, automatic syntax
checking is not performed and the Exit Option window is not displayed.

123
Control-M/Analyzer User Guide

Balancing Mission Definition Facility


The Control-M/Analyzer Balancing Mission Definition facility is composed of a series of screens that enable
you to view, create and modify the parameters of balancing missions.
Control-M/Analyzer Balancing mission parameters are stored in libraries (partitioned data sets). A library
contains members, and each member contains rule categories of one or more mission definitions.
Although most sites designate a primary mission definition library, the number of balancing mission
definition libraries that you can use is unlimited.
Note: Members contain mission definitions – not the JCL of the member. The number of rules in a library,
the number of mission definitions in a member, and the size of each mission definition, are all calculated
dynamically and are not dependent on parameter specification or optional ZAPs.

Accessing the Balancing Mission Definition Facility


The Balancing Mission Definition facility contains the screens described in Table 61.
Table 61 Balancing Mission Definition Screens

Screen Description

Mission Definition Allows specification of parameters that determine which screen is


entry panel displayed.

Mission List screen Displays the list of missions in the specified library.

Category List screen Displays the list of mission definitions in a specific job table.

Mission Definition Displays the parameters of the selected mission definition. This
screen screen is used to define, display and modify mission definition
parameters.

To enter the Balancing Mission Definition facility, select Option BM on the IOA Primary Option menu and
press Enter. The entry panel is displayed.

Creating Members
Members can be created in any of the following ways:
 By specifying the new mission name in the entry panel and pressing Enter.
 By using the SELECT command (described later) to specify the new mission name in the Mission List
screen and pressing Enter.
As a result of using either of the above methods, a skeletal mission definition (meaning, one with most
fields left blank) is displayed in the Mission Definition screen.
Fill in the blanks and save the screen entries. The mission is created with the specified mission definition.
The mission definition is the first and only definition in the Category List for the mission. As additional
mission definitions are created in the mission (described below), they are added to the Category list.

124
Control-M/Analyzer User Guide

Note: Upon exiting the Category List screen, if changes were made in at least one mission definition, and
Exit Option window is displayed. One field of the window displays the mission name. This value can be
changed to a new mission name that creates a new mission in which the mission definitions are saved.

Creating Mission Definitions


Mission definitions can be created using two basic methods:
 A skeletal mission definition can be created by specifying the name of a new mission definition in the
entry panel. (The mission specified in the entry panel can be either a new mission or an existing
mission.) In this case, virtually all fields of the mission definition are empty.
 A copy of an existing mission definition can be created using the INSERT option (described later) in
the Category List screen. In this case, most fields of the new mission definition have the same values
as the fields in the copied mission definition.

Performing Operations on Missions and Mission Definitions


Many operations can be performed on missions and on mission definitions in them. These operations are
performed using commands and options in the various screens of the Balancing Mission Definition facility.
Below is a brief summary of some of the major operations possible within the facility. Additional options
and commands that have not yet been explained are explained in detail following the summary.

Accessing (Editing or Browsing) a Mission and its Mission Definitions


A mission and its definitions can be browsed or edited.
When browsed, the mission cannot be modified or updated. When the mission is edited, new mission
definitions can be added and existing mission definitions can be modified or deleted.
Browsing, however, has advantages:
 Access and exit are quicker than in editing.
 Mission definitions that are in use by another user can be viewed.
 Access for browsing might be granted, even though access for editing might be denied due to site
security requirements.
To browse a mission (and its category list and mission definitions), use the BROWSE option in the Mission
List screen.
Specifying the mission name in the entry panel or using the SELECT option in the Mission List screen
provides edit access.
Depending on the user profile definitions, if the table requested for editing is in use, either access is
granted in Browse mode or access will not be granted.

Copying a Mission Definition to Another Mission


Mission definitions can be copied from one mission to another using the COPY option in the Category List
Screen. For more information, see Copying Balancing Mission Definitions to Another Mission (on page
144).

125
Control-M/Analyzer User Guide

Deleting a Mission or a Mission Definition


Unneeded mission definitions can be deleted using the DELETE option in the Category List screen. For
more information, see Options of the Category List Screen (on page 132). Unneeded missions can be
deleted using the DELETE option in the Mission List Screen. For more information, see Deleting Missions
(on page 130).

Ordering Multiple Missions


More than one mission at a time can be ordered at one time. To select multiple missions, TAB down to
each mission in the Mission List screen that you want to select and type O next to the desired mission.
Press Enter. A popup confirmation window is displayed, prompting you to choose whether to view the
confirmation window for each mission.
If you choose not to view the confirmation screen before viewing each mission (Confirm Y, Ask For Each
One N), click Enter.

Saving Modifications
All changes made to a mission and its mission definitions are kept in memory until the mission is exited.
Upon exiting the mission, the user can choose to save or cancel the changes. For more information, see
Exiting the Mission Definition Screen (on page 140).

Entry Panel
Figure 52 Control-M/Analyzer Mission Definition – Entry Panel
---------- CONTROL-M/ANALYZER MISSION DEFINITION - ENTRY PANEL-------------(BM)
COMMAND ===>

SPECIFY LIBRARY, MISSION NAME, CATEGORY

LIBRARY ===> CTB.PROD.BALMIS


MISSION ===> (Blank for mission selection list)
CATEGORY ===> (Blank for category selection list)

SHOW DOCUMENTATION ===> N (Y/N)


AUTO-SAVE DOCUMENTATION ===> Y (Y/N)

USE THE COMMAND "SHPF" TO SEE PFK ASSIGNMENT 12.03.11

Note: If you use the selection list fields, their values are not erased until you exit the entry panel by
pressing END (PF03/PF15).

126
Control-M/Analyzer User Guide

To open the desired display, fill in Entry Panel fields LIBRARY, MISSION, and CATEGORY as described
below. Type Y (Yes) or N (No) in the SHOW DOCUMENTATION field to display or hide mission
documentation. Type Y (Yes) or N (No) in the AUTO-SAVE DOCUMENTATION field to auto-save
documentation changes. For more information on the SHOW DOCUMENTATION and AUTO-SAVE
DOCUMENTATION parameters, refer to Mission Documentation (on page 138).
 To display the list of missions in a library, do the following:
1. Type the library name.
2. Leave the mission name blank or type part of the mission name using mask characters (* and ?).
3. Press Enter.

 To display the list of mission definitions for a specific mission, do the following:
4. Type the library name.
5. Type the mission name.
6. Press Enter.
If the mission does not exist, the screen for defining a mission is displayed.

 To display the details of a specific mission definition for a specific mission (Mission Definition screen),
do the following:
7. Type the library name.
8. Type the mission name.
9. Type the category name.
10. Press Enter.
If the mission does not exist, or the mission definition for the specified mission does not exist, the screen
for defining a new mission definition in the mission is displayed.
Note: If you enter the screen for defining a new mission definition and want to leave the screen without
defining a mission definition, use the CANCEL command.
 To display the Search Window (described below), do the following:
11. Type the library name.
12. Type the mission definition (category) name.
13. Leave the mission name blank or type the mission name using mask characters (* and ?).
14. Press Enter.
To create a new mission: Specify the new mission name and press Enter. The Mission Definition screen,
for defining the first mission definition in the new mission, is displayed.

127
Control-M/Analyzer User Guide

Search Window
The Search window allows the user to search for the specified mission definitions in missions in the
specified library. Missions in which the mission definition have been found are then displayed in the
Mission List screen.
Figure 53 Control-M/Analyzer Mission Definition – Search Window
---------- CONTROL-M/ANALYZER MISSION DEFINITION - ENTRY PANEL -------------(BM)
COMMAND ===>

SPECIFY LIBRARY, MISSION NAME, CATEGORY

LIBRARY ===> CTBP.PROD.BALMIS


MISSION ===> (Blank for mission selection list)
CATEGORY===> CTBSAMPLE (Blank for category selection list)
E-------------------------------------------N
| |
| PLEASE SELECT ONE OF THE FOLLOWING: 1 |
| |
| 1 s STOP SEARCH IMMEDIATELY |
| 2 s ASK AGAIN AFTER 000010 MEMBERS |
| 3 s UNCONDITIONAL SEARCH |
SHOW DOCUMENTATION ===> | |
AUTO-SAVE DOCUMENTATION ===> | NUMBER OF MEMBERS IN LIBRARY: 000004 |
| NUMBER OF SEARCHED MEMBERS: 000000 |
| NUMBER OF SELECTED MEMBERS: 000000 |
| |
D-------------------------------------------M
USE THE COMMAND "SHPF" TO SEE PFK ASSIGNMENT 18.04.01

To close the Search Window without performing any action, press END (PF03/PF15).
To perform a search, select one of the following choices and press Enter:
3 - UNCONDITIONAL SEARCH
This performs an uninterrupted search of all tables in the specified library.
The search is stopped immediately when you select Option 1.
2 - ASK AGAIN AFTER number MEMBERS
This searches the specified number of members in the specified library, and then pauses. The search
number can be modified. Default:10.
 Continue the search by pressing Enter.
 Stop the search by selecting Option 1 (Stop Search Immediately).
If any members are found, the Mission List is displayed listing those members.
During the search, the following information is displayed at the bottom of the window:

128
Control-M/Analyzer User Guide

 Number of members in library – lists the total number of members in the specified library.
 Number of searched members – lists the cumulative number of members searched. For example, if
you perform three searches with a specified number of 10, the figure displayed is 30.
 Number of selected members – lists the cumulative number of members selected that contain the
mission definition being searched.
If any members are selected during the search, the Mission List is displayed listing those members. If no
members are selected, the Search Window is closed and a message is displayed.

Mission Definition Facility – Mission List


The screen displays a list of missions (members) in the specified library. This screen is entered using the
entry panel or when returning from the Category List screen.
By default, only member names are listed in the screen. However, if the default has been modified,
statistical information is displayed for each member name (as illustrated in Figure 54).
Use the scrolling conventions to scroll the Mission list forward and backward.
Figure 54 Mission Definition Facility – Mission List Screen
MISSION LIST IN CTB.PROD.BALMIS ------------(BM)
COMMAND ===> SCROLL ===> CRSR
OPT NAME ------------ VV.MM CREATED CHANGED SIZE INIT MOD ID
ACCT 01.01 99/11/23 99/12/29 17:07 16 16 0 M17
ADMIN 01.01 99/11/23 99/12/29 17:07 7 7 0 M17
BACKUP 01.00 99/11/18 00/04/04 16:09 23 23 0 M27A
GRAPHIX 01.03 99/11/18 99/12/29 09:26 9 9 0 M66
INVENTRY 01.01 99/07/27 00/04/04 15:34 8 8 0 M27A
MAINT 01.01 99/07/27 00/04/04 15:34 16 16 0 M27
MARKET 01.01 99/07/27 00/04/04 15:34 8 8 0 M47A
PROF306 01.01 99/07/27 00/04/04 15:34 22 22 0 M25A
YEAREND 01.05 99/07/08 00/02/02 14:30 8 8 0 M43A
====== >>>>>>>>>>>>>>>> NO MORE MISSIONS IN LIBRARY <<<<<<<<<<<<<< =====

OPTIONS: S SELECT O ORDER F FORCE B BROWSE D DELETE 19.20.17

To return to the Mission Definition entry panel, press END (PF03/PF15).

Options of the Mission List Screen


To use one of the options described in Table 62, specify the option in the OPT field to the left of the
mission name and press Enter:

129
Control-M/Analyzer User Guide

Table 62 Options of the Mission List Screen

Option Description

S (SELECT) See a list of categories in a mission.

O (ORDER) Order a mission for balancing based on Basic Scheduling parameters


(described later in this chapter).

F (FORCE) Force a balancing mission order regardless of the Basic Scheduling


parameters of the mission (described later in this chapter).

B (BROWSE) Display a list of categories in a mission for browsing. Only one


mission may be selected at a time.

D (DELETE) Delete a balancing mission from the Mission list. A confirmation


window is displayed before the mission is deleted.

Deleting Missions
To delete missions, type D in the OPT field to the left of the mission names and press Enter.
The confirmation window illustrated in Figure 55 is displayed, in sequence, for each mission selected for
deletion.
Figure 55 Mission Definition Facility – Delete Screen
MISSION LIST IN CTB.PROD.BALMIS ------------(BM)
COMMAND ===> SCROLL ===> CRSR
OPT NAME ------ VV.MM CREATED CHANGED SIZE INIT MOD ID
ACCT +--------------------------+ 16 0 M17
ADMIN | CONFIRM DELETE OPTION | 7 0 M17
D BACKUP <-----------| Y (Y/N) | 23 0 M27A
GRAPHIX +--------------------------+ 9 0 M66
INVENTRY 01.01 98/07/27 00/01/12 15:34 8 8 0 M27A
MAINT 01.01 98/07/27 00/01/12 15:34 16 16 0 M27
D MARKET 01.01 98/07/27 00/01/12 15:34 8 8 0 M47A
PROF306 01.01 98/07/27 00/01/12 15:34 22 22 0 M25A
D YEAR END 01.05.98/07/08 00/01/18 14:30 8 8 0 M43A
====== >>>>>>>>>>>>>>>> NO MORE MISSIONS IN LIBRARY <<<<<<<<<<<<<< =====

OPTIONS: S SELECT O ORDER F FORCE B BROWSE D DELETE 19.20.17

Type Y (Yes) in the confirmation window to delete the mission.


Type N (No) to cancel the deletion request.
Note: If PDSMAN is operational at your site, $$$SPACE members cannot be deleted.

130
Control-M/Analyzer User Guide

For each mission deleted, a message is written to the IOA Log file.

Mission Definition Facility – Category List


The screen displays the list of categories of a mission in a specified library. This screen can be entered
directly using the Balancing Mission Definition entry panel, by the Mission List screen, or when returning
from the Mission Definition screen.
Note: If the S (Select) option was specified in the Mission List screen for a table that is currently in use
(selected) by another user, then the Category List screen is not displayed and the Mission List screen
remains displayed (the default) or the Category List screen is displayed in Browse mode (if a User Profile
definition overrides the default). In either case, an appropriate message is displayed.
Figure 56 Mission Definition Facility – Category List Screen
CATEGORIES OF LIB CTB.PROD.BALMIS BAL MIS ADMIN
COMMAND ===> SCROLL ===> CRSR
OPT NAME ---------------------------------------------------------------------
DAILY DAY END INVENTORY PROCEDURES
MONTHLY MONTHLY INVENTORY PROCEDURES
YEARLY YEARLY INVENTORY PROCEDURES
====== >>>>>>>>>>>>>>>> NO MORE CATEGORIES IN THE MISSION <<<<<<<<<<<<<< =====

OPTIONS: S SELECT D DELETE I INSERT O ORDER F FORCE 12.04.44

The category description appears to the right of the category name. Use the scrolling conventions to scroll
the Category list forward and backward.

Format of the Category List Screen


Next to each mission definition name in the Category list, certain information can be displayed. The type
and format of this information depends on whether the screen is displayed in DESC format or in STAT
format:
 In DESC format, the description of the mission definition, taken from the DESC field of the mission
definition, is displayed. Default.
 In STAT format, the ISPF statistical information of the mission definition is displayed.
By default, the Category list is displayed in DESC format. To change formats, use the DESC or STAT
commands, described below.

131
Control-M/Analyzer User Guide

Commands of the Category List Screen


The commands described in Table 63 can be specified in the COMMAND field of the Category List screen.
Table 63 Commands of the Category List Screen

Command Description

DESC The DESC command displays the description of the mission


definition next to the mission definition name. The description is
taken from the DESC field in the mission definition.

STAT The STAT command displays the following ISPF-like statistical


information about the mission definition next to the mission
definition name: version and modification numbers, creation date,
last modification date, and user ID.

Options of the Category List Screen


To use one of the following options, specify the option in the OPT field to the left of the category name
and press Enter:
Note: If the Category List screen is displayed in Browse mode, the D (Delete) and I (Insert) options are
not available.
Table 64 Options of the Category List Screen

Option Description

S (SELECT) Display the Mission Definition screen, with details of the specific
category.
Note: If the Category List screen is not displayed in Browse mode,
the balancing mission definition can be edited and updated. If the
Category List screen is displayed in Browse mode, the balancing
mission definition can be browsed, but it cannot be modified.

132
Control-M/Analyzer User Guide

Option Description

D (DELETE) Delete a category from the Category list. When exiting the Category
List screen, a confirmation window is displayed before the category
is deleted.

I (INSERT) Insert a new category in the list. The Mission Definition screen
appears, with the same details as the category marked "I", but the
CATEGORY and DESCRIPTION parameters are empty for you to fill
in. The new category is added after the category marked "I".

O (ORDER) Order a category of a mission based on Basic Scheduling


parameters (described later in this chapter).

F (FORCE) Force a category order regardless of its Basic Scheduling


parameters.

C (COPY) Copy the mission definition to another mission (described later in


this chapter). Multiple definitions can be copied.

Mission Definition Screen


This screen is used to define, display and modify scheduling parameters of a balancing mission. This
screen can be entered directly from the Balancing Definition entry panel or from the Category List screen.
Scheduling parameters can fill more than one screen. They are organized as a sheet of paper that can be
"stretched" to any desired length. Use the scrolling conventions to scroll the decollating parameters
forward and backward.
For a detailed explanation of balancing mission parameters, see Mission Definition Parameters (on page
527).
Note: Parameters marked with the symbol M can have many occurrences. Whenever you fill in the last
occurrence of the parameter on the screen, Control-M/Analyzer adds a new empty occurrence of that
parameter that you may fill in. The only limit to the number of occurrences is the region size available for
the application.
To delete a parameter on the screen, simply erase it by pressing the EOF key or blank it out. If additional
operations are required, Control-M/Analyzer issues appropriate instructions.
Balancing mission parameters are divided into the following basic groups:
1. General Mission parameters
2. Basic Scheduling parameters
3. Runtime Scheduling parameters
4. Rule Execution parameters
The groups are separated on the screen by a delimiter line.

133
Control-M/Analyzer User Guide

Figure 57 Rule Definition Screen


CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTRY -------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTRY
JOB M43GO STEP STEP01 , CTB01 SCOPE JOB
RULENAME REORDER RULELIB CTB.PROD.RULES
OWNER M43A GROUP ACCT_INV
DESC
DOCMEM INVENTRY DOCLIB PROD.CTB.DOC
===========================================================================
DAYS ALL DCAL
AND/OR
WDAYS WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN END_OF_MONTH_OK ODAT +
TIME FROM 1500 TO 2400 NOT LATER THAN 2000 PRIORITY
===========================================================================
SET VARS TRACE=ON,
VAL=VAL
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 12.11.58

134
Control-M/Analyzer User Guide

General Mission Parameters


General Mission parameters provide basic information about the mission.
Figure 58 General Mission Parameters
+-----------------------------------------------------------------------------+
CATEGORY MONTHLY MISSION INVENTRY
JOB M43GO STEP STEP01 , CTB01 SCOPE JOB
RULENAME REORDER RULELIB CTB.PROD.RULES
OWNER M43A GROUP ACCT_INV
DESC
DOCMEM INVENTRY DOCLIB PROD.CTB.DOC

===========================================================================

Table 65 General Mission Parameters

Parameter Description

CATEGORY Category of the mission (for example, DAILY, MONTH-END,


YEAR-END).

MISSION Name of the mission.

JOB Name of the job from which the mission acts.

STEP Job steps from which the mission acts.

SCOPE Extent to which a mission can be executed, for example, only once,
several times by a single job step, several times by the same job, or
many times by any jobs.

RULENAME Name of the rule to be executed.

RULELIB Name of the library in which the rule resides.

ID of the user who owns this mission.a


OWNER

GROUP Name of user-defined group to which the mission belongs


(meaning, ACCOUNTING, PAYROLL).a

Note: If you specify the OWNER or GROUP parameter here in the mission definition, you
will override the corresponding parameter in the rule definition.

DESC Description of the mission (free text).

DOCMEM Name of the member containing the mission documentation.

DOCLIB Name of the library containing the mission documentation member.

135
Control-M/Analyzer User Guide

Basic Scheduling Parameters


Basic Scheduling parameters specify on what dates the mission can be activated. These parameters are
relevant only under certain implementation techniques. For more information see the INCONTROL for
z/OS Administrator Guide.
Figure 59 Basic Scheduling Parameters
===========================================================================
DAYS DCAL
AND/OR
WDAYS WCAL
MONTHS 1- 2- 3- 4- 5- 6- 7- 8- 9- 10- 11- 12-
DATES
CONFCAL SHIFT RETRO N MAXWAIT 99
MINIMUM PDS
===========================================================================

Table 66 Basic Scheduling Parameters

Parameter Description

DAYS Days of the month to activate this mission. A maximum of two lines
can be specified.
 DCAL – DAYS calendar specification.
 AND/OR – Conjunctional parameter that links parameters DAYS
and WDAYS.
– A (AND) Both DAYS and WDAYS criteria must be met in
order for a mission to be activated.
– O (OR) Either DAYS or WDAYS criteria must be met in
order for a mission to be activated. Default.

WDAYS Days of the week to activate the mission. A maximum of two lines
may be specified.
 WCAL – WDAYS calendar specification.

MONTHS Months to activate the mission.

DATES Specific dates in the year to activate the mission.


===========================================================================
DAYS DCAL
AND/OR
WDAYS WCAL
MONTHS 1- 2- 3- 4- 5- 6- 7- 8- 9- 10- 11- 12-
DATES
CONFCAL SHIFT RETRO N MAXWAIT 99
MINIMUM PDS
===========================================================================

136
Control-M/Analyzer User Guide

Table 67 Additional Basic Scheduling Parameters

Parameter Description

CONFCAL Name of a calendar used for mission activation confirmation.


SHIFT indicates if and when a mission should be activated when it
fails confirmation by the CONFCAL calendar. Valid values are:
 blank – Do not activate the mission. Default.
 < – Shift the scheduling date to the previous CONFCAL working
day.
 > – Shift the scheduling date to the next CONFCAL working day.

RETRO Valid values are:


 Y (Yes) – The mission is to be activated (retroactively) after the
original scheduling date has passed.
 N (No) – The mission is not to be activated after the original
scheduling date has passed. Default.

MAXWAIT Number of "extra chance" days to try to activate a mission if the


original scheduling date of the mission has passed.

MINIMUM Minimum number of free tracks in a PDS (partitioned data set)


under which the mission is activated. The mission is activated if the
number of free tracks is less than the minimum.

PDS Name of partitioned data set (library) to be checked for free space.

137
Control-M/Analyzer User Guide

Runtime Scheduling Parameters


These parameters specify the conditions that must exist before the mission is eligible for activation.
Figure 60 Runtime Scheduling Parameters
===========================================================================
IN END_OF_MONTH_OK ODAT +

TIME FROM 1500 TO 2400 NOT LATER THAN 2000 PRIORITY


===========================================================================

Table 68 Runtime Scheduling Parameters

Parameter Description

IN M Prerequisite conditions that must exist before the rule is activated.


After filling in the prerequisite condition name and pressing Enter,
Control-M/Analyzer creates a field for entering a date reference.
(Default = Control-M/Analyzer working date.)

TIME Time limits (FROM, UNTIL) for executing the mission.

NOT LATER THAN Time by which the mission is activated even if prerequisite
conditions do not exist.

PRIORITY For future use.

Rule Execution Parameters


Rule Execution parameters set Local and System variables that control rule execution.
Table 69 Rule Execution Parameters

Parameter Description

SET VARS For future use.

Mission Documentation
Displaying Documentation
Depending on the value of the SHOW DOCUMENTATION field in the Mission Definition entry panel,
mission documentation (DOC lines) is either displayed or hidden when you first enter the Mission
Definition screen, as follows:
If the SHOW DOCUMENTATION field is set to Y, mission documentation is displayed upon entry to the
Mission Definition screen.

138
Control-M/Analyzer User Guide

If the SHOW DOCUMENTATION field is set to N, documentation is hidden upon entry to the Mission
Definition screen.
DOC Command
The DOC command alternately displays and hides the documentation of the mission.
Below is an example of the Mission Definition screen with documentation (DOC lines) displayed.
Figure 61 Mission Definition Screen with Documentation (DOC) Lines Displayed
-- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTRY ------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTRY
JOB M43G0 STEP STEP01 , CTB01 SCOPE JOB
RULENAME REORDER RULELIB CTB.PROD.RULES
OWNER M43A GROUP ACCT_INV
DESC SCHEDULES REORDER RULE DAILY
DOCMEM INVENTRY DOCLIB PROD.CTB.DOC
===========================================================================
DOC THIS SCREEN SHOWS WHERE MISSION DOCUMENTATION APPEARS ON THE SCREEN
DOC WHEN YOU USE THE DOC COMMAND.
DOC AS YOU CAN SEE, THE LINES FOLLOWING THE DOCUMENTATION ARE "PUSHED"
DOC DOWNWARD. ENTER THE DOC COMMAND AGAIN TO MAKE THIS MISSION
DOC DOCUMENTATION AREA DISAPPEAR.
DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 15.04.55

Note: If you have DOCU/TEXT installed at your site you may specify a DOCU/TEXT library and member
with up to 132 characters per line. However, if more than the first seven characters in a line are used, the
line is truncated and Browse mode is forced. Browse mode may also be forced if a line has an unprintable
character.
Editing Documentation
Documentation may be edited when the DOC lines of the Mission Definition screen are displayed. Modify
the DOC lines as desired. When you fill in the last DOC line and press Enter, a new DOC line is displayed.
When modifying DOC lines, text must be left in at least one DOC line in order to save the modifications.
Changes resulting in an empty DOCMEM member are not saved.
Mission documentation is written to the library member specified in the DOCMEM and DOCLIB fields on
the Mission Definition screen. Therefore, it is also possible to edit the documentation directly through ISPF
edit of the member. This is recommended when documentation is lengthy or the editing required is very
complex.
Note: For LIBRARIAN and PANVALET users, the DOC command displays or hides mission documentation
in Browse mode. Changes to the documentation are not permitted.
AutoSave and Saving Documentation
Documentation changes can be saved upon exiting the Mission Definition screen. When there are
documentation changes, a Save Documentation window may be displayed depending on the value of the
AUTO-SAVE DOCUMENTATION field in the entry panel:

139
Control-M/Analyzer User Guide

If AUTO-SAVE DOCUMENTATION is set to Y, documentation changes are automatically saved and the
Save Documentation window is not displayed.
If AUTO-SAVE DOCUMENTATION is set to N, documentation changes are not automatically saved and the
Save Documentation window is displayed. This window lets you save or cancel the documentation
changes.

Figure 62 Save Documentation Window


- CONTROL-M/ANLAYZER CATEGORY DAILY BAL MISSION INVENTRY -------(BM.S)
COMMAN +-----------------------------------------------------------+ ===> CRSR
+----- | | --------+
CATE | SAVE DOCUMENTATION ==> (Y/N) |
JOB | |
RULE | LIBRARY PROD.CTB.DOC |
OWNE | MEMBER M43G0 |
DESC | |
DOCM +-----------------------------------------------------------+
==== =======
DOC THIS SCREEN SHOWS WHERE MISSION DOCUMENTATION APPEARS ON THE SCREEN
DOC WHEN YOU USE THE DOC COMMAND.
DOC AS YOU CAN SEE, THE LINES FOLLOWING THE DOCUMENTATION ARE "PUSHED"
DOC DOWNWARD. ENTER THE DOC COMMAND AGAIN TO MAKE THIS MISSION
DOC DOCUMENTATION AREA DISAPPEAR.
DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 15.04.55

The parameters described in Table 70 can be specified in the Save Documentation window.
Table 70 Save Documentation Window Parameters

Parameter Description

SAVE Valid values are:


DOCUMENTATION
 Y (Yes) – Save documentation changes.
 N (No) – Do not save documentation changes.

LIBRARY Name of the library containing the documentation member.

MEMBER Name of the member containing the documentation.

Modify the LIBRARY and MEMBER values if desired, and specify Y (Yes) or N (No) in the SAVE
DOCUMENTATION field; then press Enter.
If there are no documentation changes, the Save Documentation window is not displayed.

Exiting the Mission Definition Screen


Use the commands described in Table 71 to exit the Mission Definition screen.

140
Control-M/Analyzer User Guide

Table 71 Commands for Exiting the Mission Definition Screen

Command Description

END Keep the changes made to the parameters of the category of the
mission and return to the Category List screen. Automatic syntax
checking is performed. See Saving a Balancing Mission Definition
(on page 142).

CANCEL Do not keep the changes made to the parameters of the category of
the mission and return to the Category List screen. See Canceling
Changes (on page 142).

NEXTCTG Keep the changes made to the parameters of the category of the
mission and display the next category in the Category list.

PREV+++++++CTG Keep the changes made to the parameters of the category of the
mission and display the previous category in the Category list.

Note: Changes made to the parameters are only kept in memory. They are written to the disk after you
exit the Category List screen.

Automatic Syntax Checking


The definition syntax is automatically checked when you exit the Mission Definition screen using the END,
NEXTCTG or PREVCTG command.
If errors are found, you remain in the Mission Definition screen and an error message is displayed. You
may then correct the errors.
If no errors are found, you exit to the Category List screen.
If you exit the Mission Definition screen by the CANCEL or RESET command, automatic syntax checking is
not performed.

141
Control-M/Analyzer User Guide

Saving a Balancing Mission Definition


Press END (PF03/PF15) to exit the Mission Definition screen. Press END (PF03/PF15) again to exit
the Category List screen. If changes have been made in the Balancing Mission Definition facility (and no
errors are found during automatic syntax checking), an Exit Option window is opened.
Figure 63 Exit Option Window
CATEGORIES OF LIB CTB.PROD.BALMIS BAL MIS INVENTRY
COMMAN +-----------------------------------------------------------+ ===> CRSR
OPT N | PLEASE SELECT EXIT OPTION | ---------
M | |
===== | SAVE CREATE | <<< =====
DA | |
MO | LIBRARY CTB.PROD.BALMIS |
YE | MISSION INVENTRY |
| |
+-----------------------------------------------------------+

OPTIONS: S SELECT D DELETE I INSERT O ORDER F FORCE 13.20.42

You must enter Y (Yes) or N (No) in one of the exit options. It is possible to change the name of the
library or the name of the mission in the window. You then return to the Mission List screen or to the
entry panel, depending on where you were when you entered the Category List screen.
The changes made to the balancing parameters of one category of a mission can be saved only by saving
all the categories of that mission using the Exit Option window.

Canceling Changes
If you do not want to save mission definition changes, specify the CANCEL command in the Mission
Definition screen, or specify the CANCEL command in the Category List screen, or specify the RESET
command in the Exit Option window. As a result, you return to the Category list and the changes are not
saved.

Ordering Balancing Missions


The Mission Definition screen is used to define Balancing Mission parameters and scheduling criteria. This
definition becomes "active" only after it is ordered. The mission can be ordered automatically each day, as
described in Chapter 6, "Mission Definition Parameters," or manually. One of the ways to manually order
one or more missions is by using the O and F options of the Mission or Category List screens.

142
Control-M/Analyzer User Guide

The options can be activated from:


 Mission List screen – all balancing mission categories in the selected missions are ordered.
 Category List screen – only the selected category are ordered.
The options described in Table 72 can be used to order a mission.
Table 72 Options for Ordering a Mission

Option Description

O (ORDER) Schedule the categories of the mission only if the specified date is
defined as a scheduling date in the Basic Scheduling parameters of
the category.

F (FORCE) Schedule the categories of the mission regardless of Basic


Scheduling parameters.

When you use the O and F options, the confirmation window illustrated in Figure 64 is opened.
Figure 64 Order and Force Confirmation Window
MISSION LIST IN CTB.PROD.BALMIS -------------(BM)
COMMAND ===> SCROLL ===> CRSR
OPT NAME ---------------------------------------------------------------------
ACCT
ADMIN
BACKUP +-------------------------------+
GRAPHIX | CONFIRM ODATE 030399 |
O INVENTRY <-----------| ASK FOR EACH ONE Y |
MAINT +-------------------------------+
MARKET
PROF306
YEAREND
====== >>>>>>>>>>>>>>>> NO MORE MISSIONS IN LIBRARY <<<<<<<<<<<<<< =====

OPTIONS: S SELECT O ORDER F FORCE D DELETE 13.22.14

You can change the specified date. To affirm your selection, enter Y in the CONFIRM field. If you decide
not to order the mission or category, enter N (for CANCEL). You then return to the original screen.
If you specify many O or F options in a screen, it may be tedious to affirm each one. To skip the
Confirmation window, type N in the ASK FOR EACH ONE field and press Enter. All the missions or
categories marked O or F are ordered without individual confirmation.
Each mission that is successfully scheduled (ordered) is displayed on the screen illustrated in Figure 65.

143
Control-M/Analyzer User Guide

Figure 65 Control-M/Analyzer Mission Order Messages Screen


------------- CONTROL-M/ANALYZER MISSION ORDER MESSAGES -----------------(BM.O)
COMMAND ===> SCROLL===> CRSR
-------------------------------------------------------------------------------
14.54.05 BAO501I CTBBAO STARTED
14.54.09 BAO528I MEMBER INVENTRY ID=0005D ODATE 030399 PLACED ON ACTIVE BALANC
14.54.10 BAO528I MEMBER INVENTRY ID=0005E ODATE 030399 PLACED ON ACTIVE BALANC
14.54.10 BAO528I MEMBER INVENTRY ID=0005F ODATE 030399 PLACED ON ACTIVE BALANC
14.54.10 BAO525I CTBBAO ENDED
====== >>>>>>>>>>>>>>>>> END OF MESSAGE LIST <<<<<<<<<<<<<<<<< =====

PRESS END TO RETURN. LEFT AND RIGHT TO SEE MORE. 14.54.39

Press the END command (PF03/PF15) to return to the Mission or Category List screen.

Copying Balancing Mission Definitions to Another Mission


To copy one or more mission definitions from the current mission another mission, type C (Copy) by the
mission names in the Category List screen and press Enter. The window illustrated in Figure 66 is
displayed.
Figure 66 Window for Copying Balancing Mission Definitions to Another Member
CATEGORIES OF LIB CTBP.PROD.BALMIS BAL MIS ADMIN
COMMAND ===> SCROLL ===> CRSR
OPT NAME ----------------- DESCRIPTION ---------------------------------------
C DAILY DAILY BALANCING MISSION FOR ACCOUNTS RECEIVABLE
WEEKLY END OF WEEK SUMMARY REPORT
MONTHLY MONTHLY REPORTING MISSION FOR A/R
====== >>>>>>>>>>>>>>>> NO MORE CATEGORIES IN THE MISSION <<<<<<<<<<<<<< =====
+-----------------------------------------------------------+
| |
| SPECIFY DESTINATION LIBRARY, MEMBER AND CATEGORY NAME |
| |
| LIBRARY : CTBP.PROD.BALMIS |
| MEMBER : |
| CATEGORY: DAILY |
| |
| PRESS END/RESET TO CANCEL ENTER TO PERFORM THE COPY |
+-----------------------------------------------------------+

OPTIONS: S SELECT D DELETE I INSERT O ORDER F FORCE C COPY 14.14.45

The window contains the fields described in Table 73. Some fields contain default values that can be
modified.

144
Control-M/Analyzer User Guide

Table 73 Files in the Window for Copying Mission Definitions to Another Member

Field Description

LIBRARY Library containing the table into which the balancing mission
definitions should be copied. Must be an existing library. Default is
the current library.

MISSION Name of the mission into which the balancing mission definition
should be copied.

Note: A balancing mission definition can only be copied to another


mission. It cannot be copied to its own mission (even if the mission
definition is renamed).
If the specified mission does not exist, the mission is created when
the request is performed.

CATEGORY Name of the balancing mission definition to be copied. If the


multiple balancing definitions are selected, the window is initially
displayed with the first selected mission definition. As each request
is performed or canceled, the next requested mission definition
name is displayed

To perform a request, press Enter.


To cancel a request, press END (PF03/PF15) or RESET (PF04/PF16).

Balancing Status Facility


The Control-M/Analyzer Active Balancing Environment screen displays the status of all tasks (rules)
currently in the Active Balancing file. On this screen, you can view the status of the rules and modify their
work flow. The SHOW command is used to specify online selection criterion. For more information, see
Specifying Retrieval Criteria (on page 147).

Active Balancing Environment Screen


To enter the Active Balancing Environment screen, select Option BB on the IOA Primary Option menu.
Use the scrolling conventions to scroll the screen forward and backward.

145
Control-M/Analyzer User Guide

Figure 67 Active Balancing Environment Screen


----------- CONTROL-M/ANALYZER ACTIVE BALANCING ENVIRONMENT -----<D>---------(BB)
COMMAND ===> SCROLL===> CRSR
O RULE ODATE SCP OWNER JOBNAME ---------- STATUS ----------------------
TEST1 000505 JOB M43 M43BLL BALANCING
RULINVD 000505 ALL M18B M18TINVD BALANCING
RULINV 000505 ALL M18B M18TINV ENDED "OK" CODE=0000
TEST2 000505 ALL M43 M43GO ENDED "OK" CODE=0000
ADM_INV 000505 ALL M18B ADMIN BALANCING
TEST3 000505 ALL M43 M43G1 WAIT ACTIVATION
CURRMARK 000505 ALL M18B CURRMIS ENDED "OK" CODE=0000
CURRMARK 000505 ALL M31A CURRMIS ENDED NOT "OK" CODE=4091
RULINV 000505 ALL M18B M18TINV BALANCING
RULINVE 000505 ALL M18B M18TINVE WAIT ACTIVATION
RULINVD 000505 ALL M18B M18TINVD WAIT ACTIVATION
======= >>>>>>>>>>>>>>>>>>>> BOTTOM OF ACTIVE RULES <<<<<<<<<<<<<<<<<<< =======

OPTIONS: ? WHY H HOLD D DEL F FREE L LOG 11.31.00

On color terminals, rules with different statuses are displayed with different colors. The indicated colors
have been defined as defaults for the rule statuses described in Table 74 (discussed inStatus (on page
153)).
Note: See your INCONTROL administrator to change color definitions.
Table 74 Color Defaults for Rule Statuses

Colors Description

Blue and White Rules that are waiting to be activated.

Yellow Rules that are executing.

Green Rules that ended OK.

Turquoise Rules that ended TOLER (meaning, within tolerance, the range of
permissible deviation).

Red Rules that ended NOTOK.

Pink Rules that require special user action (for example, Held, Deleted).

146
Control-M/Analyzer User Guide

Specifying Retrieval Criteria


Different retrieval criteria can be specified by using the SHOW command. Type SHOW in the COMMAND
field and press Enter, or press SHOW (PF02/PF14). A Show Option window appears on the screen.
Change the selection criteria and press Enter. Only rules conforming to the selection criteria are
displayed.
Figure 68 Active Balancing Environment Screen Show Option Window
------------ CONTROL-M/ANALYZER ACTIVE BALANCING ENVIRONMENT -----<D>--------(BB)
COMMAND ===> +----------------------------------------------------------+
O RULE ODATE | PLEASE SELECT SHOW OPTION |
TEST1 000505 | RULE |
RULINVD 000505 | JOBNAME |
RULINV 000505 | MISSION |
TEST2 000505 | CATEGORY |
ADM_INV 000505 | GROUP |
TEST3 000505 | |
CURRMARK 000505 | IN PROCESS Y | ENDED Y | STATE Y |
CURRMARK 000505 | -------------------+-----------------+-------------- |
RULINV 000505 | WAIT ACTIVATION Y | ENDED OK Y | HELD Y |
RULINVE 000505 | BALANCING Y | ENDED NOTOK Y | DELETED N |
RULINVD 000505 | | ENDED TOLER Y | FREED Y |
======= >>>>>>>>>> | === SCOPE === |
| SNG STP JOB ALL UNS |
| Y Y Y Y Y |
| COND |
| IN CONDITIONS YES Y NO Y |
| OWNER |
+----------------------------------------------------------+

OPTIONS: ? WHY H HOLD D DEL F FREE L LOG 12.03.14

Pressing RESET (PF10/PF22) in the Show Option window restores the previous criteria and closes the
window.
Note: The selection criteria below marked with the symbol P act on a prefix basis. For example, a show
limit on JOBNAME D4 results in the retrieval of all jobs whose names start with D4.
Available selection criteria are described in Table 75.

147
Control-M/Analyzer User Guide

Table 75 Selection Criteria

Criterion Description

RULEP Show only rules of the specified names. A maximum of five rule
names can be specified.

JOBNAMEP Show only rules of the specified job names. A maximum of five job
names can be specified.

MISSIONP Show only rules of the specified mission names. A maximum of five
mission names can be specified.

CATEGORYP Show only rules of the specified category names. A maximum of two
category names can be specified.

GROUPP Show only rules of the specified groups. A maximum of four groups
can be specified.

Job Status Select only rules that conform to the status selection criteria. Set
the wanted statuses to Y and the unwanted statuses to N. Status
selection criteria:
 IN PROCESS – If set to Y, rules that are not yet finished are
displayed in accordance with "wait activation" and balancing
criteria. If set to N, in process rules are not displayed.
 WAIT ACTIVATION – Rules waiting to be activated.
 BALANCING – Rules that are balancing (currently active).
 ENDED – If set to Y, finished rules are displayed in accordance
with the ENDED OK, ENDED NOTOK and ENDED TOLER criteria.
If set to N, finished rules are not displayed.
 ENDED OK – Rules that ended OK.
 ENDED NOTOK – Rules that ended NOTOK.
 ENDED TOLER – Rules that ended within tolerance.
 STATE – If set to Y, rules that have a status are displayed in
accordance with the HELD, DELETED and FREED criteria. If set
to N, rules that have a status are not displayed.
 HELD – Rules in HELD state.
 DELETED – Rules that were deleted.

Note: The default value for DELETED is N. If IN PROCESS, ENDED


and STATE are all set to N, no rules are displayed.
 FREED – Previously held rules that were released.

148
Control-M/Analyzer User Guide

Criterion Description

SCOPE Show only wanted rules that conform to the scope selection criteria.
Set the wanted scopes to Y and the unwanted scopes to N. Scope
selection criteria:
 SNG – Rules with a scope of SINGLE (rules that can be
activated once).
 STP – Rules with a scope of STEP (rules that can be activated
several times for a job step).
 JOB – Rules with a scope of JOB (rules that can be activated
several times for a job).
 ALL – Rules with a scope of ALL (rules that can be activated
several times for any jobs).
 UNS – Unscheduled rules that were activated directly without
being scheduled by a mission.
 CONDH – Show only rules that have the specified prerequisite
condition in the IN parameter. A maximum of 2 prerequisite
conditions can be specified.

IN CONDITIONS An additional cross reference for all rules with or without


prerequisite conditions in the IN parameter:

COND IN CONDITIONS Result

Y Y Show all rules.

N N Show no rules.

Y N Show only rules with


prerequisite conditions in
the IN parameter.

N Y Show only rules without


prerequisite conditions in
the IN parameter.

Note: If both COND and IN CONDITIONS are specified in the


SHOW window, field IN CONDITIONS has priority and field COND is
ignored.

OWNERH Show only rules of the specified owner. A maximum of five owners
can be specified.

149
Control-M/Analyzer User Guide

Format Commands of the Active Balancing Environment Screen


Table 76 Format Commands of the Active Balancing Environment Screen

Command Description

GROUP The GROUP command alternately displays and hides the group of
each rule. Specify the command in the COMMAND field and press
Enter.

CATEGORY The CATEGORY command alternately displays and hides the


category of each rule. Specify the command in the COMMAND field
and press Enter.

MISSION The MISSION command alternately displays and hides the mission
of each rule. Specify the command in the COMMAND field and press
Enter.

DESC The DESC command alternately displays and hides the description
of each rule. Specify the command in the COMMAND field and press
Enter.

Display Types and Fields


Rules in the Active Balancing Environment screen can be displayed in predefined formats called display
types. Each display type displays different field combinations that are useful to Control-M/Analyzer users.
Users can define and change their own display types. For details see the Control-M/Analyzer chapter of
the INCONTROL for z/OS Installation Guide. The predefined display types and the fields they contain are
discussed below.
Changing Display Types
You can change the display type by using the DISPLAY command.
The format of the command is:
DISPLAY x

In this command format, x is the identifying letter for the desired type. DISPLAY can be abbreviated DI.
Example
DISPLAY U

displays the User display type.

150
Control-M/Analyzer User Guide

Display Type D (Default)


The Default display type is illustrated in the screen illustrated in Figure 69.
Figure 69 Display Type D (Default)
----------- CONTROL-M/ANALYZER ACTIVE BALANCING ENVIRONMENT -----<D>--------(BB)
COMMAND ===> SCROLL===> CRSR
O RULE ODATE SCP OWNER JOBNAME ---------- STATUS ----------------------
TEST1 000505 JOB M43 M43BLL BALANCING
RULINVD 000505 ALL M18B M18TINVD BALANCING
RULINV 000505 ALL M18B M18TINV ENDED "OK" CODE=0000
TEST2 000505 ALL M43 M43GO ENDED "OK" CODE=0000
ADM_INV 000505 ALL M18B ADMIN BALANCING
TEST3 000505 ALL M43 M43G1 WAIT ACTIVATION
CURRMARK 000505 ALL M18B CURRMIS ENDED "OK" CODE=0000
CURRMARK 000505 ALL M31A CURRMIS ENDED NOT "OK" CODE=4091
RULINV 000505 ALL M18B M18TINV BALANCING
RULINVE 000505 ALL M18B M18TINVE WAIT ACTIVATION
RULINVD 000505 ALL M18B M18TINVD WAIT ACTIVATION
======= >>>>>>>>>>>>>>>>>>>> BOTTOM OF ACTIVE RULES <<<<<<<<<<<<<<<<<<< =======

OPTIONS: ? WHY H HOLD D DEL F FREE L LOG 11.31.06

Table 77 Fields in the Default Display Type

Field Description

O Option to be activated on the rule.

RULE Name of the rule.

ODATE Original scheduling date of the rule.

SCP Scope – extent to which a mission can be executed, for


example, only once, several times by a single job step, several times
by the same job, or many times by different jobs.

OWNER User ID of the owner of the rule.

JOBNAME Job name that invoked the rule.

STATUS Rule (task) status.

Display Type A (All Fields)


The All Fields Display type is illustrated in the screen illustrated in Figure 70.

151
Control-M/Analyzer User Guide

Figure 70 Display Type A (All Fields)


------------ CONTROL-M/ANALYZER ACTIVE BALANCING ENVIRONMENT -----<A>--------(BB)
COMMAND ===> SCROLL===> CRSR
O RULE ODATE SCP OWNER JOBNAME ---------- STATUS ----------------------
TEST1 000505 JOB M43 M43BLL BALANCING
GROUP: INV_TEST
CATEGORY: DAILY
MISSION: ST_TEST DESC:
JOB STEPNAME: STEP01
PROC STEPNAME: STEP01

RULINVD 990303 ALL M18B M18TINVD BALANCING


GROUP: INVENTORY
CATEGORY: DAILY_D
MISSION: INVMISS DESC: INVENTORY BALANCE
JOB STEPNAME: STEP01
PROC STEPNAME: STEP02

RULINV 990303 ALL M18B M18TINV ENDED "OK" CODE=0000


GROUP: INVENTORY
CATEGORY: WEEKLY
MISSION: INVMISS DESC: INVENTORY BALANCE
JOB STEPNAME: STEP02
PROC STEPNAME: STEP02
OPTIONS: ? WHY H HOLD D DEL F FREE L LOG 11.51.49

Table 78 Fields in the All Fields Display Type

Field Description

O Option to be activated on the rule.

RULE Name of the rule.

ODATE Original scheduling date of the rule.

SCP Scope. The extent to which a mission can be executed (for


example, only once, several times by a single job step, several times
by the same job, or many times by different jobs).

OWNER User ID of the owner of the rule.

JOBNAME Job name that invoked the rule.

STATUS Rule (task) status.

GROUP Name of user-defined group to which the rule belongs (for


example, ACCOUNTING, PAYROLL).

CATEGORY Category of the rule (for example, DAILY, MONTH_END).

MISSION Name of the mission associated with the rule.

DESC Free text description of the rule.

JOB STEPNAME Step name of the job that invoked the rule.

152
Control-M/Analyzer User Guide

Field Description

PROC STEPNAME Step name of the procedure that invoked the rule.

Status Field
The Status field displays information regarding the current status of the rule. The information in the
Status field consists of a rule state prefix and the status (as described below).

Rule State Prefix


The prefix indicates the current status of the rule:
Table 79 Rule State Prefixes

State Description

HELD Rule is in HELD status. Prefix HELD is displayed before subsequent


status information.

DELETED Rule has been deleted by an authorized user. Only prefix DELETED
is displayed (meaning, no other information appears in the Status
field).

blank Rule is in FREED status.

Status
Table 80 Rule State Statuses

Status Description

WAIT ACTIVATION Rule is waiting to be activated.

BALANCING Rule is balancing.

ENDED OK Rule finished balancing OK.

ENDED NOTOK Rule ended NOTOK.

ENDED TOLER Rule ended within tolerance.

Status BALANCING is followed by Balancing Line (see below).


Statuses ENDED OK, ENDED NOTOK, and ENDED TOLER are followed by CODE= (see below).

153
Control-M/Analyzer User Guide

Balancing Line
If the status of the rule is BALANCING, information about rule invocations that are currently being
balanced is displayed in the following format:
xxxxxxxx yyy
In this format
 xxxxxxxx is the name of the most recent invocation in the Active Balancing file of the same rule that
is currently running.
 yyy is the number of invocations of the same rule that are currently running.

Code
If the status of the rule is ENDED OK, ENDED NOTOK, or ENDED TOLER, the condition code is displayed:
CODE=nnnn

In this statement, nnnn is a 4-digit number representing the condition code of the terminated rule.

Suffix
A suffix is displayed for rules that have been invoked more than once. The suffix displays information
about the most recent invocation of the same rule that has already ended. Information is displayed in the
following format:
LAST INV (jobname | jobid | jstep) ENDED OK | NOTOK | TOLER CODE=code

In this statement
 jobname is the Job name.
 jobid is the Job ID.
 jstep is the Job step.
 code is the 4-digit number representing the condition code of the terminated rule.

154
Control-M/Analyzer User Guide

Sum Line
The sum line is displayed for rules that have been invoked more than once. The sum line displays the
number of rule invocations, how many ENDED OK, how many ENDED NOTOK, and how many ENDED
TOLER. Information is displayed in the following format:
RUNS-wwww, OK-xxx, NOTOK-yyy, TOLER-zzz

In this statement
 wwww is a 4-digit number representing the total number of invocations of the rule.
 xxx is a 3-digit number representing the number of invocations that ended OK.
 yyy is a 3-digit number representing the number of invocations that ended NOTOK.
 zzz is a 3-digit number representing the number of invocations that ended TOLER.
Note: Additional information can be displayed by issuing the DESC, GROUP, CATEGORY, and MISSION
commands. This information is displayed after the entire Status field (including its prefixes and suffixes).
For additional information about these commands see Format Commands of the Active Balancing
Environment Screen (on page 150).

Options of the Active Balancing Environment Screen


The options that are available in the Active Balancing Environment screen are described in Table 81. To
use one of these options, type the option in the OPT field to the left of the rule and press Enter.
Table 81 Options of the Active Balancing Environment Screen

Option Description

? (WHY) Display the Why screen (described immediately below) showing the
reasons for the Wait Activation Status.

H (HOLD) Hold the rule. Only Control-M/Analyzer operations concerning the


rule are held. If the rule is currently in the rule queue of the
operating system, or is executing, the rule itself is not held.

D (DEL) Delete the rule.

FREE Free a held rule. All Control-M/Analyzer operations concerning the


rule are freed.

LOG Display the IOA Log screen (described in IOA Log Screen (on page
195)) showing all Log messages for the specified rule.

155
Control-M/Analyzer User Guide

Why Screen
The Why screen, which is illustrated in Figure 71, is displayed when the ? (WHY) option is entered on the
Active Balancing Environment screen. The Why screen shows the reasons a rule has Wait Activation
status.
Figure 71 Active Balancing Environment Why Screen
---------------------------- INVENTORY IS WAITING FOR: -------------------(BB.?)
COMMAND ===> SCROLL===> CRSR

WAITING FOR JOB TO BE SUBMITTED


====== >>>>>>>>>>>>>>>>>> END OF "WHY" LIST <<<<<<<<<<<<<<<<<< ======

PRESS END PFK TO RETURN TO ACTIVE BALANCING ENVIRONMENT SCREEN 15.11.15

Use the scrolling conventions to scroll the Why screen forward and backward.
To return to the Active Balancing Environment screen, press END (PF03/PF15).
Possible WHY reasons are described in Table 82.
Table 82 Possible WHY Reasons

Reason Description

TIME LIMIT FROM hhmm The rule can only be executed during the indicated time
UNTIL hhmm range.

COND condition-name A prerequisite condition required by the rule (along with its
ODATE mmdd original scheduling date) does not exist.

156
Control-M/Analyzer User Guide

Rule Log Screen


The Rule Log screen is displayed when the L (Log) option is specified on the Active Balancing
Environment screen. The Rule Log screen, which is illustrated in Figure 72, shows all Log messages of the
specified rule.
Figure 72 Rule Log Screen
---------------------- LOG MESSAGES FOR JOB(S) M42XWRK ----------------(BB.LOG)
COMMAND ===> SCROLL===> CRSR
SHOW LIMIT ON == USERID GROUP MEM/MIS JOBNAME CATEGORY DATE 020200 - 020200
DATE TIME ODATE USERID CODE ------------- M E S S A G E -------------
020200 142900 020200 A CTB009I BAL (NOMISS) M42XWRK /10788 GROUP-MODE IS
"ACTIVE"
020200 142901 020200 A CTB00AI BAL (NOMISS) M42XWRK /10788 INVOKED
RULE=SYS
020200 142901 020200 A CTB013I BAL (NOMISS) M42XWRK /10788 ENDED "INERR"
COMMITTED 0 VARIABLE(S) USER RC=4091
020200 142901 020200 A CTB002I BAL (NOMISS) M42XWRK /10788 CONTROL-M/ANA
LYZER RUNTIME ENVIRONMENT ENDED
020200 143042 020200 A CTB001I BAL (NOMISS) M42XWRK /10789 CONTROL-M/ANA
LYZER RUNTIME ENVIRONMENT STARTED - MODE IS
STAND-ALONE - SCOPE IS UNSCHEDULED
020200 143042 020200 A CTB009I BAL (NOMISS) M42XWRK /10789 GROUP-MODE IS
"ACTIVE"
020200 143042 020200 A CTB00AI BAL (NOMISS) M42XWRK /10789 INVOKED
RULE=SYS
020200 143043 020200 A CTB013I BAL (NOMISS) M42XWRK /10789 ENDED "OK"
COMMITTED 0 VARIABLE(S) USER RC=0000
020200 143043 020200 A CTB002I BAL (NOMISS) M42XWRK /10789 CONTROL-M/ANA
LYZER RUNTIME ENVIRONMENT ENDED
CMDS: SHOW, GROUP, CATEGORY, SHPF 16.25.01

Usage of the Rule Log screen is explained in detail in IOA Log Screen (on page 195).
Note: The IOA Log screen can be accessed by typing =5 in the command field and pressing Enter.
The Show Screen Filter window can be opened in the Rule Log screen to create or modify a filter. For
information on how to use the SHOW command (PF02/PF14) see IOA Log Show Screen Window (on
page 199).
To return to the Active Balancing Environment screen, press END (PF03/PF15).

Rule Activity Display Facility


The Rule Activity display is the main end-user interface to Control-M/Analyzer balancing information.
Each time a Control-M/Analyzer rule is invoked (an "invocation"), a rule activity record is generated. A job
that invokes Control-M/Analyzer five times creates five activity records that are displayed in the Rule
Activity display.
Rule activity records that satisfy the selection criteria specified in the Rule Activity entry panel are listed.
The user can select entries in this list to view the results of the balancing process.

157
Control-M/Analyzer User Guide

From the Rule Activity display the user can


 retrieve a list of invocations according to given selection criteria
 view a balancing report online
 view the IOA Log file
 examine the variables created by a specific invocation
 request additional information for any invocation
 read the IOA Log file entries for a given invocation
 print the Rule Activity report for a given invocation on the printer or copy it to a data set
 view Rule Activity statistics in the View Graph by Group screen
 "roll back" (return) the Control-M/Analyzer Database to its state before a specific invocation

Rule Activity Entry Panel


Upon entering option BA (Rule Activity display) from the IOA Primary Option menu, the Rule Activity entry
panel is displayed.
The Rule Activity entry panel enables you to specify selection criteria and display options for invocations.
Fill in the selection criteria and display options. Press Enter to display a list of all invocations that conform
to the selection criteria in the Rule Activity display.
You can bypass the Rule Activity entry panel and display the Rule Activity display directly by entering Y in
the Bypass panel field of the Rule Activity entry panel.
Figure 73 Rule Activity Entry Panel
-------------- CONTROL-M/ANALYZER - RULE ACTIVITY ENTRY PANEL ------------------ (BA)
COMMAND/OPTION ===>

SELECT BY:
GROUP ===> * Group name or * for all groups
USERID ===> Userid name or prefix
JOBNAME ===> Job name or prefix
STEPNAME(S) ===> Step name(s)
REMARK ===> Remark or prefix
RULE ===> Rule name
CATEGORY ===> Site-defined category or mask
DATE FROM ===> TO Job date
TIME FROM ===> TO Job time

SELECT BY STATUS:
OK ===> Y
Not OK ===> Y
In tolerance ===> Y

DISPLAY OPTIONS:
Bypass panel ===> N
Display type ===> D

FILL IN THE SELECTION CRITERIA, AND PRESS ENTER 12.16.05

158
Control-M/Analyzer User Guide

Rule Activity Entry Panel Fields


From the Rule Activity entry panel you can specify selection criteria to control which invocations appear in
the Rule Activity display.
SELECT BY
The SELECT BY selection criteria that are marked In Table 83 with the symbol P permit character masking
and act on a prefix basis. Prefixing is explained in Prefixing (on page 61), and character masking is
explained in Character Masking (on page 62).
Table 83 SELECT BY Selection Criteria

Field Description

GROUP Group name for the rule.

USERID User name. Default is the current user.

JOBNAMEP Name of the job.

STEPNAME(S) Job step names. A maximum of two job steps can be specified.

REMARKP Invocation remarks.

RULEP Rule name.

CATEGORYP Site-defined category name (for example, DAILY, MONTHLY).

DATE FROM/TO Earliest and latest activity date. Date criteria are matched against
the following dates:
 ODATE (Original scheduling date).
 Invocation start date.
Dates can be specified as follows:
 mmddyy or ddmmyy format, depending on the site standard.
 –n, where n is the number of preceding days (any value from 0
through 365). Example: –3 means three days ago.
A FROM date expressed without a TO date implies that the FROM
and TO date are the same.
The Rule Activity entry panel retains the value specified in this field
when exiting and reentering the entry panel or Rule Activity Display
screen.
Example:
DATE FROM –2 TO 0
If today is Thursday, invocations are included from Tuesday,
Wednesday, and Thursday. If today is Friday, invocations are
included from Wednesday, Thursday, and Friday.

159
Control-M/Analyzer User Guide

Field Description

TIME FROM/TO Earliest and latest rule processing time of day. Time format is
hhmm. Time criteria are matched against:
 Rule invocation start time
 Rule invocation end time
If TIME FROM is "later" than TIME TO, time is calculated from the
FROM time until midnight and from midnight until the TO time (for
example, from 1000 to 0800 means anytime except between 8:00
a.m. and 10:00 a.m.).

SELECT BY STATUS
Only invocations that meet selected invocation status criteria are displayed:
Table 84 SELECT BY STATUS Selection Criteria

Field Description

OK Invocations that have terminated and have met all data balancing
specifications.

Not OK Terminated invocations that did not meet data balancing


specifications and did not terminate within reasonable tolerance
levels.

Intolerance Invocations that did not meet data balancing specifications but did
terminate within user-defined tolerance levels.

160
Control-M/Analyzer User Guide

DISPLAY OPTIONS
Table 85 Display Options

Option Description

Bypass panel This parameter determines whether the Rule Activity entry panel is
displayed the next time you enter the Rule Activity facility. Valid
values are:
 Y – Bypass the Rule Activity entry panel and enter the Rule
Activity display directly (using the last set of values entered).
 N – Display the Rule Activity entry panel the next time you
enter the Rule Activity facility.

Display type Specifies the desired display type (or format) of the Rule Activity
display. Valid values are:
 A – All Fields
 U – User – for end users
 D – Default – for operations personnel

Examples of these types are provided later in this chapter. Additional display types can be defined. See
the discussion about display types in the INCONTROL for z/OS Installation Guide.

Bypassing the Entry Panel


When Y (Yes) is specified in the Bypass panel field in the Rule Activity entry panel, the Rule Activity
display is immediately displayed whenever you enter the Rule Activity facility. (The Rule Activity display is
discussed below.)
When bypassing the Rule Activity entry panel, the selection criteria previously specified in the entry panel
are applied to the Rule Activity display.

Reaccessing the Entry Panel


After you have set the Bypass panel field to Y, you can access the Rule Activity entry panel by pressing
the END key (PF03/PF15) from a Rule Activity Display screen.
To access the entry panel the next time you enter the Rule Activity facility, set the value of the Bypass
panel field to N.

Rule Activity Display


Invocations that meet the selection criteria specified in the Rule Activity entry panel are listed in the Rule
Activity display.

161
Control-M/Analyzer User Guide

Header Line
The Rule Activity display has a header line at the top of the screen indicating the main selection criteria
values that were specified.
Table 86 Rule Activity Display Header Line

Field Description

DISPLAY TYPE # Code letter (for example, U – User)

GROUP Group name

USER ID User name (or prefix or mask – as specified)

JOBNAME Job name (or prefix or mask – as specified)

Rule Activity List Display Types and Fields


For each kind of Rule Activity display, a number of predefined display types are available. These
predefined types and the fields they contain are discussed below.
Changing Display Types
You can change the display type by using the DISPLAY command. The format of the command is:
DISPLAY x

In this command, x is the identifying letter for the desired type. DISPLAY can be abbreviated DI.
Example
DISPLAY U

displays the User display type.

162
Control-M/Analyzer User Guide

Display Type A (All Fields)


The All Fields display type is illustrated in Figure 74.
Figure 74 Display Type A (All Fields) Screen
RULE ACTIVITY <A> GROUP * USERID JOBNAME
COMMAND ===> SCROLL===> CRSR
O JOBNAME JOBID STEPNAME GROUP OWNER INV#
M18CTB 4234 STEP02 ACCOUNTS M18CTB 0001
Rule : WHEN1 Mission: (NOMI) Category : (NO-CATEGORY)
Date : 04/04/00 Start : 20:37 End : 20:38
Status : OK Code : 0000 Committed: 0001 Variables
Remark :
Report : N
-------------------------------- end of data ----------------------------------
M55ATB 5738 STEP02 CTB12345 ACCOUNTS M55ATB 0001
Rule : WHEN1 Mission: (NOMI) Category : (NO-CATEGORY)
Date : 05/05/00 Start : 12:08 End : 12:08
Status : OK Code : 0000 Committed: 0001 Variables
Remark :
Report : Y
-------------------------------- end of data ----------------------------------
M43BLL 5758 STEP02 CTB12345 ACCOUNTS M43BLL 0001
Rule : TEST1 Mission: (NOMI) Category : (NOCATEGORY)
Date : 05/05/00 Start : 12:20 End : 12:20
Status : OK Code : 0000 Committed: 0001 Variables
Remark :
Report : Y
OPTIONS: V VIEW L LOG R REPORT B ROLL BACK P PRINT 14.21.2

Fields in the All Fields Display Type


Table 87 Fields in the All Fields Display Type

Field Description

O Option to be activated on the job.

JOBNAME Name of the job that invoked the mission or rule.

JOBID Job ID of the job that invoked the mission or rule.

STEPNAME Job step (including program and procedure names) that invoked the
mission or rule.

GROUP Group name of the mission or rule. For more information, see
"GROUP" in Table 78 in Display Type A (All Fields) (on page 151).

OWNER Owner of the mission or rule.

Note: If the GROUP or OWNER parameter is specified in the mission definition, it overrides
the corresponding parameter, if any, in the rule definition.

163
Control-M/Analyzer User Guide

Field Description

INV# Control-M/Analyzer invocation number of the current job.

Rule Name of the rule.

Mission Name of the mission.

Category Category of the mission.

Date Date that the rule ran.

Start Time that the rule started.

End Time that the rule ended.

Status Result of invoking the rule.

Code Completion code of the invocation.

Committed Number of Database variables committed by the rule.

Remark Remarks generated by rule statement DO REMARK.

Report Invocation report created by the rule (Y=Yes, N=No).

164
Control-M/Analyzer User Guide

Display Type D (Default)


The Default display type is illustrated in Figure 75.
Figure 75 Display Type D (Default) Screen
RULE ACTIVITY <D> GROUP * USERID JOBNAME
COMMAND ===> SCROLL===> CRSR
O JOBNAME JOBID STEPNAME DATE START ENDED RULE STATUS CODE
M18CTB 4234 STEP01 08/08/00 20:37 20:38 WHEN1 OK 0000
M55ATB 5738 STEP01 CTB12345 08/08/00 12:08 12:08 WHEN1 OK 0000
M43BLL 5758 STEP11 CTB12345 08/08/00 12:20 12:20 TEST1 OK 0000
M18TINVD 5849 STEP01 CTB12345 08/08/00 13:13 13:13 RULINVD OK 0000
M18TINV 5876 STEP32 CTB12345 08/08/00 13:24 13:25 RULINV OK 0000
M43G0 5894 STEP33 CTB12345 08/08/00 13:46 13:46 TEST2 OK 0000
ADMIN 4127 STEP01 07/17/00 18:36 18:36 ADM_INV INERR ****
M43G1 4134 STEP21 08/08/00 18:39 18:39 TEST3 OK 0000
CURRMIS 4145 STEP02 08/08/00 18:46 18:46 CURRMARK OK 0000
CURRMIS 5732 STEP02 CTB12345 08/08/00 12:03 12:03 CURRMARK INERR ****
M18TINV 5749 STEP43 CTB12345 08/08/00 12:17 12:17 RULINV OK 0000
M18TINVE 5799 STEP01 CTB12345 08/08/00 12:43 12:43 RULINVE OK 0000
M18TINVD 5807 STEP01 CTB12345 08/08/00 12:46 12:47 RULINVD INERR ****
M18CTB 5857 STEP02 CTB12345 08/08/00 13:15 13:15 WHEN1 INERR ****
M55CTB 5886 STEP05 CTB12345 08/08/00 13:38 13:38 TEST1 OK 0000
M43BLL 5916 STEP22 CTB12345 08/08/00 14:06 14:06 TEST1 INERR ****
M43BLL 5918 STEP10 CTB12345 08/08/00 14:07 14:07 TEST1 OK 0000
M18TINVD 5926 STEP11 CTB12345 08/08/00 14:12 14:12 RULINVD OK 0000
M18TINV 5932 STEP43 CTB12345 08/08/00 14:15 14:15 RUILNV OK 0000
M43GO 5964 STEP02 CTB12345 08/08/00 14:35 14:35 TEST2 OK 0000
OPTIONS: V VIEW L LOG R REPORT B ROLL BACK P PRINT 12.20.03

Fields in the Default Display Type


Table 88 Fields in the Default Display Type

Field Description

O Option to be activated on the job.

JOBNAME Name of the job that invoked the mission or rule.

JOBID Job ID of the job that invoked the mission or rule.

STEPNAME Job step (including program and procedure names) that invoked the
mission or rule.

DATE Date that the rule ran.

START Time that the rule started.

ENDED Time that the rule ended.

RULE Name of the rule.

STATUS Result of the invocation.

CODE Condition code of the invocation.

165
Control-M/Analyzer User Guide

Display Type U (User)


The User display type is illustrated in Figure 76.
Figure 76 Display Type U (User)
RULE ACTIVITY <U> GROUP * USERID JOBNAME
COMMAND ===> SCROLL===> CRSR
O JOBNAME JOBID DATE START ENDED RULE STATUS CODE REMARK
M18CTB 4234 08/08/00 20:37 20:38 WHEN1 OK 0000
M55ATB 5738 08/08/00 12:08 12:08 WHEN1 OK 0000
M43BLL 5758 08/08/00 12:20 12:20 TEST1 OK 0000
M18TINVD 5849 08/08/00 13:13 13:13 RULINVD NOTOK 0008
M18TINV 5876 08/08/00 13:24 13:25 RULINV OK 0000
M43GO 5894 08/08/00 13:46 13:46 TEST2 OK 0000
ADMIN 4127 08/08/00 18:36 18:36 ADM_INV INERR ****
M43G1 4134 08/08/00 18:39 18:39 TEST3 OK 0000
CURRMIS 4145 08/08/00 18:46 18:46 CURRMARK OK 0000
CURRMIS 5732 08/07/00 12:03 12:03 CURRMARK INERR ****
M18TINV 5749 08/08/00 12:17 12:17 RULINV OK 0000
M18TINVE 5799 08/08/00 12:43 12:43 RULINVE OK 0000
M18TINVD 5807 08/08/00 12:46 12:47 RULINVD INERR ****
M18CTB 5857 08/08/00 13:15 13:15 WHEN1 INERR ****
M55CTB 5886 08/08/00 13:38 13:38 WHEN1 OK 0000
M43BLL 5916 08/08/00 14:06 14:06 TEST1 INERR ****
M43BLL 5918 08/08/00 14:07 14:07 TEST1 TOLER 0000
M18TINVD 5926 08/08/00 14:12 14:12 RULINVD OK 0000
M18TINV 5932 08/08/00 14:15 14:15 RULINV OK 0000
M43G0 5964 08/08/00 14:35 14:35 TEST2 OK 0000
OPTIONS: V VIEW L LOG R REPORT B ROLL BACK P PRINT 12.21.32

Fields in the User Display Type


Table 89 Fields in the User Display Type

Field Description

O Option to be activated on the job.

JOBNAME Name of the job that invoked the mission or rule.

JOBID Job ID of the job that invoked the mission or rule.

DATE Date that the rule ran.

START Time that the rule started.

ENDED Time that the rule ended.

RULE Name of the rule.

STATUS Result of the invocation.

CODE Condition code of the invocation.

REMARK Remarks generated by rule statement DO REMARK.

166
Control-M/Analyzer User Guide

Invocation Results on the Rule Activity Display


The STATUS field indicates the result of the mission or rule invocation. Table 90 shows the results that
may appear.
Table 90 Invocation Results on the Rule Activity Display

Result Description

OK Invocation terminated successfully and data are in balance.

NOTOK Invocation terminated successfully but data are not in balance.

TOLER Invocation terminated successfully and data, even though not


balanced, are within tolerance levels.

INERR Invocation terminated unsuccessfully (due to an environmental


error). The data could not be balanced and are assumed to be
NOTOK.

By typing Y (Yes) in one or more of the SELECT BY STATUS fields in the Rule Activity entry panel, it is
possible to view only those invocations that ended with the specified statuses.

Rule Activity Display Commands


General Commands
Use the scrolling conventions to scroll the Rule Activity display forward and backward.
Use the FIND command to search for a specified string in the Rule Activity display.
Use the END command (PF03/PF15) to exit the Rule Activity display and return to the Rule Activity
entry panel.
Use the =X command to exit the online Rule Activity facility. You are then returned to your normal
operating environment.

167
Control-M/Analyzer User Guide

Table 91 Commands of the Rule Activity Display

Command Description

REFRESH The REFRESH command (PF04/PF16) refreshes the display of


the current Rule Activity display. The selection criteria are
reactivated and a new list is produced containing invocations that
were added to the list since the last time the list was displayed. The
command also refreshes the status of the existing invocations in the
list.

DISPLAY While in a Rule Activity display, you can change the display type by
using the DISPLAY command. The format of the command is:
DISPLAY x
where x is the identifying letter for the desired type. DISPLAY may
be abbreviated DI.
Example
DISPLAY U
displays the User type of the Rule Activity display.

GRAPH The GRAPH command (abbreviated G) displays the View Graph by


Group screen (described below). Type the command or its
abbreviation on the Command line of the Rule Activity display and
press Enter.

168
Control-M/Analyzer User Guide

Options of the Rule Activity Display


The options described in Table 92 can be applied to individual invocations.
Table 92 Options of the Rule Activity Display

Option Description

V (VIEW) View the variables created and accessed by the rule (described
earlier in Database Facility – Variable List (on page 92)). Variables
cannot be modified or deleted under this option.

L (LOG) View the IOA Log file entries created by the invocation (described in
IOA Log Facility (on page 195)).

REPORT View the Rule Activity report created by the invocation. This option
can be applied to invocations with a Report field specification of Y.
When this option is selected, the Control-M/Analyzer Rule Activity
Report screen is displayed. Messages that appeared during the
Control-M/Analyzer invocation are listed. For additional information
see Rule Activity Report Viewing Screen (on page 176).

ROLL BACK Restore the Control-M/Analyzer Database to its state before the
invocation ran. For additional information see Rollback Confirmation
Window (on page 177) and Rollback Facility (on page 627).

PRINT Prints the Rule Activity report created by the invocation on the
printer or to a data set. This option can be applied to invocations
with a Report field specification of Y. When this option is selected,
the Print Option window is opened. For additional information see
Print Option Window (on page 178).

169
Control-M/Analyzer User Guide

View Graph By Group Screen


Type GRAPH (abbreviated G) in the COMMAND field of the Active Balancing Environment screen and
press Enter to display the View Graph by Group screen. This screen provides a statistical overview of the
status of Control-M/Analyzer rules in graphical form. The information is presented by GROUP.
Figure 77 View Graph By Group Screen
---------------------------- VIEW GRAPH - BY GROUP ----------------------(BA.G)
COMMAND ===> SCROLL===> CRSR
SCALE 1:1 TOTAL: ENDED NOTOK 00051 ENDED TOLER 00032 ENDED OK 00258
GROUP VALUE +---+---10----+---20----+---30----+---40----+---50
====== >>>>>>>>>>>>>>>>>> T O P O F L I S T <<<<<<<<<<<<<<<<<< ======
ACCOUNTING 13 RRRYGGGGGGGGG
ADMIN 9 RRRYGGGG
DEVELOPMENT 35 RRRRRRR
FOREIGN CURRENCY 10 RRGGGGGGG
INTERNATIONAL 7 RGGGGG
INTRAC 14 RRRRYG
LOANS 4 GGG
MANAGEMENT 8 YGGGG
MARKETING 9 RRYGGGG
PAYROLL 21 RYYYGGGGGGGGGGGGGGGG
PR 5 YGGG
PRODUCTION1 45 RRRRRYYYYGGGGGGGGGGGGGGGGGGGGGGGGGGG
PRODUCTION2 41 RRRRRRRYYYYYGGGGGGGGGGGGGGGGGGGGG
PRODUCTION3 46 RRRRRRYGGGGGGGGGGGGGGGGGGGGGGGGGGGGG
PRODUCTION4 50 RRRRRR
SALES 11 RYYGGGGG
STOCK MARKET 5 YGGGG
TRAINING 8 RYGGGGG
COMMANDS: REFRESH (VIEW DATA) END (RETURN TO PREVIOUS SCREEN) 10.59.44

Use the scrolling conventions to scroll the View Graph by Group screen forward and backward. To refresh
the screen, type REFRESH in the COMMAND field of the screen and press Enter, or press PF04/PF16.
To return to the Active Balancing Environment screen, press END (PF03/PF15).
The View Graph by Group screen has two formats: one for color terminals and one for non-color
terminals. They are discussed below.

170
Control-M/Analyzer User Guide

For Color Terminals


Figure 78 View Graph By Group Screen For Color Terminals
---------------------------- VIEW GRAPH - BY GROUP ----------------------(BA.G)
COMMAND ===> SCROLL===> CRSR
SCALE 1:1 TOTAL: ENDED NOTOK 00051 ENDED TOLER 00032 ENDED OK 00258
GROUP VALUE +---+---10----+---20----+---30----+---40----+---50
====== >>>>>>>>>>>>>>>>>> T O P O F L I S T <<<<<<<<<<<<<<<<<< ======
ACCOUNTING 13
ADMIN 9 RRRYGGGG
DEVELOPMENT 35 RRRRRRRRRYYYYGGGGGGGGGGGGGGGGGGG
FOREIGN CURRENCY 10 RRGGGGGGG
INTERNATIONAL 7 RGGGGG
INTRAC 14 RRRRYGGGGGGG
LOANS 4 GGG
MANAGEMENT 8 YGGGGG
MARKETING 9 RRYGGGG
PAYROLL 21 RYYYGGGGGGGGGGGGGGG
PR 5 YGG
PRODUCTION1 45 RRRRYYYGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGG
PRODUCTION2 41 RRRRRYYYYYGGGGGGGGGGGGGGGGGGGGGGGGGG
PRODUCTION3 46 RRRRYGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGG
PRODUCTION4 50 RRRRRRRYYYYGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGG
SALES 11 RYYGGGGGG
STOCK MARKET 5 YGGGG
TRAINING 8 RYGGGG
COMMANDS: REFRESH (VIEW DATA) END (RETURN TO PREVIOUS SCREEN) 10.59.44

The screen header contains three status totals (ENDED NOTOK, ENDED TOLER and ENDED OK) for all
rules in the Active Balancing file. For details of these totals, see Table 93.
Table 93 View Graph By Group Screen Status Totals

Status Description

ENDED NOTOK Total number of rules with ended NOTOK status (red)

ENDED TOLER Total number of rules with ended TOLER status (yellow)

ENDED OK Total number of rules with OK status (green)

Scale of the Graph


The screen header indicates the scale of the graph. For example, SCALE 1:10 means that each character
position in the graph represents 10 rules. The scale is adjusted automatically so that the longest line in
the graph ends near the right margin.
Displayed Information
The graph displays the information described in Table 94 for each group:

171
Control-M/Analyzer User Guide

Table 94 View Graph By Group Information

Field Description

GROUP Name of the group.

VALUE Total number of rules in the group.

RULE STATUS The lines in the graph indicate the number of rules in each status
for each group.

Rule Graph
In the rule graph, rule statuses are differentiated by color, as described in Table 95.
Table 95 Rule Status Colors

Color Description

Red ENDED NOTOK

Yellow ENDED TOLER

Green ENDED OK

For each group in the graph, the number of columns of a particular color depends on the number of rules
having that status and the scale of the graph.
A scale line facilitates reading the number of rules of each status for a group. The scale used
(meaning, the number of rules represented by each column) is automatically adjusted based on the
number of rules in the group containing the most rules.
Commands
The View Graph by Group screen has the commands described in Table 96.
Table 96 Commands of the View Graph By Group Screen

Command Description

REFRESH Displays updated data on the screen.

END Returns to previously displayed screen.

172
Control-M/Analyzer User Guide

For Terminals Not Supporting Color


Figure 79 View Graph By Group Screen For Terminals Not Supporting Color
---------------------------- VIEW GRAPH - BY GROUP ----------------------(BA.G)
COMMAND ===> SCROLL===> CRSR
SCALE 1:1 TOTAL: ENDED NOTOK 00051 ENDED TOLER 00032 ENDED OK 00258
GROUP VALUE +---+---10----+---20----+---30----+---40----+---50
====== >>>>>>>>>>>>>>>>>> T O P O F L I S T <<<<<<<<<<<<<<<<<< ======
ACCOUNTING 13 ***+%%%%%%%%%
ADMIN 9 ***+%%%%%
DEVELOPMENT 35 *********++++%%%%%%%%%%%%%%%%%%%%%%
FOREIGN CURRENCY 10 **%%%%%%%%
INTERNATIONAL 7 *%%%%%%
INTRAC 14 ****+%%%%%%%%%
LOANS 4 %%%%
MANAGEMENT 8 +%%%%%%%
MARKETING 9 **+%%%%%%
PAYROLL 21 *+++%%%%%%%%%%%%%
PR 5 +%%%%
PRODUCTION1 45 *****++++%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
PRODUCTION2 41 *******+++++%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
PRODUCTION3 46 ******+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
PRODUCTION4 50 ******++++%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SALES 11 *++%%%%%%%%
STOCK MARKET 5 +%%%%
TRAINING 8 *+%%%%%%
Commands: REFRESH (VIEW DATA) END (RETURN TO PREVIOUS SCREEN) 14.37.58

The screen header contains three status totals (ENDED NOTOK, ENDED TOLER and ENDED OK) for all
rules in the Active Balancing file:
Table 97 View Graph By Group Screen Status Totals

Status Description

ENDED NOTOK Total number of rules with ended NOTOK status (*)

ENDED TOLER Total number of rules with ended TOLER status (+)

ENDED OK Total number of rules with OK status (%)

Scale of the Graph


The screen header indicates the scale of the graph. For example, SCALE 1:10 means that each character
position in the graph represents 10 rules. The scale is adjusted automatically so that the longest line in
the graph ends near the right margin.
Displayed Information
The graph displays the information described in Table 98 for each group:

173
Control-M/Analyzer User Guide

Table 98 View Graph By Group Information

Field Description

GROUP Name of the group.

VALUE Total number of rules in the group.

RULE STATUS The lines in the graph indicate the number of rules in each status
for each group.

Rule Graph
In the rule graph, rule statuses are differentiated by symbols, as described in Table 99.
Table 99 Rule Status Symbols

Symbol Description

* ENDED NOTOK

+ ENDED TOLER

% ENDED OK

For each group in the graph, the number of columns containing a particular symbol depends on the
number of rules having that status and the scale of the graph.
A scale line facilitates reading the number of rules of each status for a group. The scale used
(meaning, the number of rules represented by each column) is automatically adjusted based on the
number of rules in the group containing the most rules.
Commands
The View Graph by Group screen has two commands:
Table 100 Commands of the View Graph by Group Screen

Command Description

REFRESH Displays updated data on the screen.

END Returns to previously displayed screen.

174
Control-M/Analyzer User Guide

Rule Log Screen


The Rule Log screen is displayed when the L (Log) option is specified on the Rule Activity display. The
Rule Log screen shows all Log messages of the specified rule.
Figure 80 Rule Log Screen
--------------------- LOG MESSAGES FOR JOB(S) M42INSGS ----------------(BA.LOG)
COMMAND ===> SCROLL===> CRSR
SHOW LIMIT ON == USERID GROUP MEM/MIS JOBNAME CATEGORY DATE 080800 - 080800
DATE TIME ODATE USERID CODE ------------- M E S S A G E -------------
080800 114540 080800 M66 CTB009I BAL (NOMISS) M42INSGS/13530 GROUP-MODE IS
"ACTIVE"
080800 114540 080800 M66 CTB00AI BAL (NOMISS) M42INSGS/13530 INVOKED
RULE=ARWARN04
080800 114636 080800 M66 CTB013I BAL (NOMISS) M42INSGS/13530 ENDED "NOTOK"
COMMITTED 0 VARIABLE(S) USER RC=0999
080800 114636 080800 M66 CTB002I BAL (NOMISS) M42INSGS/13530 CONTROL-M/ANA
LYZER RUNTIME ENVIRONMENT ENDED
080800 114651 080800 M66 CTB001I BAL (NOMISS) M42INSGS/13530 CONTROL-M/ANA
RUNTIME ENVIRONMENT STARTED - MODE IS
LYZER STAND-ALONE - SCOPE IS UNSCHEDULED
080800 114651 080800 M66 CTB009I BAL (NOMISS) M42INSGS/13530 GROUP-MODE IS
"ACTIVE"
080800 114651 080800 M66 CTB00AI BAL (NOMISS) M42INSGS/13530 INVOKED
RULE=ARWARN4A
080800 114725 080800 M66 CTB013I BAL (NOMISS) M42INSGS/13530 ENDED "OK"
COMMITTED 6 VARIABLE(S) USER RC=0009
080800 114725 080800 M66 CTB002I BAL (NOMISS) M42INSGS/13530 CONTROL-M/ANA
LYZER RUNTIME ENVIRONMENT ENDED
CMDS: SHOW, GROUP, CATEGORY, SHPF 13.19.54

Note: The IOA Log screen can be accessed by typing =5 in the command field and pressing Enter.
The Show Screen Filter window can be opened in the Rule Log screen to create or modify a filter. For
information on how to use the SHOW command (PF02/PF14) see IOA Log Show Screen Window (on
page 199) .
To return to the Rule Activity display, press END (PF03/PF15).

175
Control-M/Analyzer User Guide

Rule Activity Report Viewing Screen


The R option displays the Rule Activity Report Viewing screen that enables you to view the Rule Activity
report for the specified invocation. The report includes messages that were generated during the
Control-M/Analyzer invocation.
Note: The R option can only be specified for invocations with a Report field specification of Y.
Figure 81 Rule Activity Report Viewing Screen
------------------- CONTROL-M/ANALYZER RULE ACTIVITY REPORT VIEWING -----------(BA.R)
COMMAND ===> SCROLL===> CRSR
-------------------------------------------------------------------------------
CTB001I- CONTROL-M/ANALYZER RUNTIME ENVIRONMENT STARTED - MODE IS STAND-ALONE - SCOPE
IS
CTB009I- GROUP-MODE IS "ACTIVE"
CTB00AI- INVOKED RULE=ARWARN01 RULE-LIB=CTB.PROD.RULES
*** CONTROL-M/ANALYZER SUMMARY OF INVOCATION REPORT ***

***---------------------------------------------------------------***
*** GROUP : INTRAC JOBNAME : M42INSGS /JOB13530 ***
*** MISSION : ARMISS01 RULE : ARWARN01 ***
*** CATEGORY: DAILY OWNER : M66 ***
*** RUN ON : 08/08/00 - 11:47 ***
***---------------------------------------------------------------***
CTB109I- Compilation started
CTB110I- Compilation completed successfully
CTB111I- Highest error code was 0
*
** ENTERING BLOCK: CHECK OF TYPE DATA
*
PRT: TIME IS NOT BETWEEN 12 P.M. AND 6 P.M.
PRT: YOU'RE OK FOR NOW, BUT DO NOT RELAX
==SHOUT : 'TIME IS NOT BETWEEN 12 P.M. AND 6 P.M --- RELAX ************' To: TS
PRESS END TO RETURN. LEFT AND RIGHT TO SEE MORE. 12.12.15

Use the scrolling conventions to scroll the Rule Activity Report screen forward and backward. Press END
(PF03/PF15) to return to the Rule Activity display.
Note: The Rule Activity report is contained in the SYSPRINT member, which is created automatically
during the Control-M/Analyzer invocation.
Control-M/Analyzer generates two other reports: the SYSUSER Report (a listing of all DO PRINT output)
and the SYSRULE report (a listing of the rule). These reports cannot be viewed online but are available in
the SYSOUT of the job that involved the rule. However, DO PRINT output is also included in the Rule
Activity report preceded by the identifier "PRT: ".

176
Control-M/Analyzer User Guide

Rollback Confirmation Window


The B option displays the Rollback Confirmation window that enables you to confirm the rollback of the
Database variables committed by the specified rule invocations.
Note: The B option can only be specified for invocations that have committed Database variables. These
invocations have a Committed field value greater than 0.
Figure 82 Rollback Confirmation Window
RULE ACTIVITY <A> GROUP * USERID JOBNAME
COMMAND ===> SCROLL===> CRSR
O JOBNAME JOBID STEPNAME GROUP OWNER INV#
M72ANS 4487 STEP01 INTRAC M66 0001
Rule : ARWARN04 Mission: (NOMISS) Category : (NO-CATEGORY)
Date : 08/08/00 Start : 11:07 End : 11:08
Status : NOTOK Code : 0999 Committed: 0000 Variables
Remark :
Report : +------------------------+
----------- | |--------------------------------
B M72ANS <--------| CONFIRM (Y/N) | M66 0001
Rule : | | (NO-CATEGORY)
Date : +------------------------+ 11:12
Status : OK Code : 0009 Committed: 0006 Variables
Remark :
Report : Y
-------------------------------- END OF DATA ----------------------------------
B M72ANSGS 4055 STEP4 INTRAC M66 0001
Rule : ARSETVAR Mission: (NOMISS) Category : (NO-CATEGORY)
Date : 08/08/00 Start : 19:22 End : 19:22
Status : OK Code : 0000 Committed: 0043 Variables
Remark :
Report : Y
OPTIONS: V VIEW L LOG R REPORT B ROLL BACK P PRINT 13.51.31

A confirmation window is displayed for each invocation selected for rollback.


Specify Y (Yes) in the window to confirm the rollback request, and press Enter. The Database variables
committed during the invocation of the rule are "deleted" and the confirmation window is closed.
Specify N (No) to cancel the rollback request, and press Enter. The Database variables are not changed
and the confirmation window is closed.
For additional information on rolling back variable values see Rollback Facility (on page 627).

177
Control-M/Analyzer User Guide

Print Option Window


The P option opens the Print Option window, which enables you to print the Rule Activity report for the
specified invocation, either to the printer or to a data set. Fields are provided in the window for the
specification of print criteria.
Note: The P option can only be specified for invocations with a Report field specification of Y.
Figure 83 Print Option Window
RULE ACTIVITY <D> GROUP * USERID JOBNAME
COMMAND ===> +---------------------------------------------------------+
O JOBNAME JOBID ST | |
M18CTB 4234 ST | PRINT OPTION ===> |
M55ATB 5738 ST | |
M43BLL 5758 ST | 1 Print report |
P M18TINVD 5849 ST | 2 Write report to data set |
M18TINV 5876 ST | X Exit (no action) |
M43G0 5894 ST | |
ADMIN 4127 ST | COPIES 001 CLASS Y |
M43G1 4134 ST | |
CURRMIS 4145 ST | DEST WTR |
CURRMIS 5732 ST | |
M18TINV 5749 ST | DSN |
M18TINVE 5799 ST | |
M18TINVD 5807 ST | APPEND Y |
M18CTB 5857 ST | |
M55CTB 5886 ST | JOBNAME M55ATB OWNER M55 RULE WHEN1 |
M43BLL 5916 ST | |
M43BLL 5918 ST +---------------------------------------------------------+
M18TINVD 5926 STEP54 08/08/99 11:52 11:54 ARSETVAR OK 0000
M18TINV 5932 STEP23 08/08/99 15:05 15:05 ARWARN01 NOTOK 0003
M43GO 5964 STEP12 08/08/99 16:11 16:11 ARWARN01 NOTOK 0003
OPTIONS: V VIEW L LOG R REPORT B ROLL BACK P PRINT 13.30.56

The options described in Table 101 are available from the Print Option window.
Table 101 Options of the Print Option Window

Option Description

1 (Print report) The Rule Activity report is sent to the printer specified in the
DEST/WTR field.

2 (Write report to The Rule Activity report is immediately written to the previously
data set) allocated data set specified in the DSN field.

X (Exit – no action) The Rule Activity report is not printed. The Print Option window is
closed and the Rule Activity display is displayed on the screen.

The parameters described in Table 102 can be modified in the Print Option window:

178
Control-M/Analyzer User Guide

Table 102 Modifiable Parameters of the Print Option Window

Parameter Description

COPIES Number of cop]ies to print when option 1 is selected. The number


of copies can be between 001 and 255.

CLASS Name of the output class to which the Rule Activity report should be
printed when option 1 is selected.

DEST Printer destination where the report should be printed when option
1 is selected (or blank for the main computer printer). Two DEST
fields are provided for the specification of remote printer
destinations. Each destination can be a maximum of eight
characters.

Note: When specifying the WTR field, only one DEST field can be
specified.

WTR Name of the external writer where the report should be printed
when option 1 is selected (or blank for the main computer external
writer).

DSN Specifies the desired display type (or format) of the Rule Activity
display.

Note: The data set specified in the DSN field must already be
catalogued.

APPEND Indication of whether the Rule Activity report should be appended


to, or overwrite the contents of, the data set specified in the DSN
field when Option 2 is selected. Valid values are:
 Y (Yes) – The current report is appended to the end of the data
set (meaning, disposition of the file is MOD).
 N (No) – The current report replaces the contents of the data
set (meaning, disposition of the file is SHR).

The fields describe in Table 103 are displayed in the Print Option window. These fields are displayed for
informative purposes and cannot be modified:

179
Control-M/Analyzer User Guide

Table 103 Non-Modifiable Fields of the Print Option Window

Field Description

JOBNAME Name of the job.

OWNER Owner of the job.

RULE Name of the rule that created the Rule Activity report.

The message "PRINT REQUEST COMPLETED OK" appears when the report is printed (either to the printer
or to a data set).
To exit the Print Option window without printing, select Option X. The Print Option window is closed and
the Rule Activity display is displayed on the screen.
Note: The Rule Activity report is contained in the SYSPRINT member, which is created automatically
during the Control-M/Analyzer invocation.

Condition and Resource Handling Facility


Options 4 and 7 in the IOA Primary Option menu are directly related to the handling of IOA conditions
and Control-M resources. The screens displayed by these options are discussed on the following pages.

IOA Conditions/Resources Screen


The IOA Conditions/Resources screen is accessed through Option 4 of the IOA Primary Option menu. It
displays information from the IOA Conditions file, which contains the list of all existing prerequisite
conditions, and the Control-M Resources file, which contains the list of Quantitative resources and Control
resources. The IOA Conditions/Resources screen enables you to
 view IOA prerequisite conditions
 view Control-M Quantitative resources
 add or delete prerequisite conditions or resources or both
 change the available quantity of Control-M Quantitative resources
For a description of prerequisite conditions, see Prerequisite Condition Concept (on page 52).
Note: Prior to version 6.0.00 a single file, the IOA Conditions/Resources File, contained all IOA conditions
and all Control and Quantitative resources. As of version 6.0.00, the IOA Conditions/Resources File has
been replaced by two files:
 IOA Conditions file - contains all IOA conditions.
 Control-M Resources file - contains all Control and Quantitative resources.
To enter the IOA Conditions/Resources screen, select Option 4 on the IOA Primary Option menu.

180
Control-M/Analyzer User Guide

Figure 84 IOA Condition/Resources Screen


-------------------------- IOA CONDITIONS/RESOURCES ------------------------(4)
COMMAND ===> SCROLL ===> CRSR
PREFIX ===> COND Y CONTROL Y RES Y STAT Y DATE 0909 - 0909
OPT TYPE CONDITION/RESOURCE IOAID USE QUANTITY MAX *P RBA DATE
CONTROL CONTROLM 01 E (00000)
RESOURCE TAPEP B 0003 0003
RESOURCE CPU1 B 0098 0100
RESOURCE CPU2 B 0197 0200
RESOURCE TAPEP 01 U 0002 (00091)
RESOURCE CPU1 01 U 0002 (00091)
RESOURCE CPU2 01 U 0003 (00092)
RESOURCE TAPEP 01 R 0002 1 (00093)
COND BR-BRIVPCC-ENDED-OK 0909
COND BR-BRCC0001-ENDED-OK 0909
COND BR-BRCC0002-ENDED-OK 0909
COND BR-BRCC0003-ENDED-OK 0909
COND BR-BRCCIND-ENDED-OK 0909
COND BR-BRUPDT02-ENDED-OK 0909
COND BR-BRREP001-ENDED-OK 0909
COND BR-BRREP002-ENDED-OK 0909
COND GL-GLINP001-ENDED-OK 0909
COND EBD-APPL-STARTED 0909
COND CICS-PROD-IS-UP STAT
OPTIONS: D DELETE C CHANGE COMMANDS: ADD 14.07.08

To return to the IOA Primary Option menu, press the END key (PF03/PF15).

181
Control-M/Analyzer User Guide

Fields of the IOA Conditions/Resources Screen


The information displayed in each screen line is described in Table 104.
Table 104 Fields of the IOA Conditions/Resources Screen

Field Description

OPT Option to be activated on the condition or resource.


Type of condition or resource:
TYPE
 COND – Prerequisite condition
 CONTROL – Control resource
 RESOURCE – Quantitative resource

CONDITION Name of the condition or resource


/RESOURCE
Original date reference of a prerequisite condition (format mmdd or
ddmm depending on the site standard, or the value STAT)
DATE

When Control-M is active at your site, information is displayed in the following fields.

USE Resource usage indicator for Control or Quantitative resources. Valid


values depend on the type of resource.
For Control resources, valid values are:
 E – Resource is being used in Exclusive mode
 S – Resource is being used in Shared mode
For Quantitative resources, valid values are:
 B – Line indicates the initial definition for the resource
 U – Line indicates an instance of resource usage
 R – Line indicates an unfulfilled critical path request (that is, a
request with an *-type priority) for the resource

QUANTITY Quantity of a Quantitative resource. What the quantity represents


depends on the value in the USE field, as follows:

Use Quantity

B Quantity available. If the maximum quantity is


more than 1 but only 1 is available, 0001 is
displayed in pink for color terminals. If the
maximum quantity is more than 1 but none is
available, 0000 is displayed in red for color
terminals.

Q Quantity in use by the particular process.

182
Control-M/Analyzer User Guide

Field Description

R Quantity requested by the particular process,


but unfulfilled.

MAX Maximum available quantity of a Quantitative resource.

*P Priority of the job requesting a Control-M resource using *-type


priority. For more information, see the Control-M for z/OS User
Guide.`

RBA Internal Control-M ID (relative byte address) of the job currently


holding a Control-M resource. An RBA value of 000000 indicates that
the resource was added manually.

Note: Line indicates an unfulfilled critical path request (that is, a


request with an *-type priority) for the resource.

IOAID ID of the IOA installation using the particular Control or Quantitative


resource. This value is significant when multiple IOA installations
share the same resources.

Specifying Retrieval Criteria


You can control the type and amount of information displayed in the screen by specifying retrieval criteria.
Table 105 IOA Conditions/Resources Retrieval Criteria

Criterion Description

PREFIX prefix If specified, limits the display to conditions with the specified prefix.
To display only conditions containing a specific string, enter the
string preceded by an *.
Example:
If *OK is entered, the following conditions are included in the
display:
UPDATE-ENDED-OK
OK-RUN
OK

183
Control-M/Analyzer User Guide

Criterion Description

COND Determines whether prerequisite conditions are displayed. Valid


values are:
 Y (Yes) – Display prerequisite conditions. Default.
 N (No) – Do not display prerequisite conditions.

DATE from – to Limits the display of prerequisite conditions to the selected date
range. Valid values are:
 from – Earliest date in the date range, in mmdd or ddmm
format (depending on the site standard). The default value is
three days prior to the current date. This default can be
modified in the Profile member by the INCONTROL
administrator.
 to – Latest date in the date range, in mmdd or ddmm format
(depending on the site standard). The default value is the
current date.

STAT Determines whether prerequisite conditions with a date value of


STAT are displayed. (Applies only if Y is specified for COND.) Valid
values are:
 Y (Yes) – Include prerequisite conditions with a date value of
STAT.
 N (No) – Do not include prerequisite conditions with a date
value of STAT.

For sites where Control-M is active:

CONTROL Determines whether Control resources are displayed. Valid values


are:
 Y (Yes) – Display Control resources. Default.
 N (No) – Do not display Control resources.

RES Determines whether Quantitative resources are displayed. Valid


values are:
 Y (Yes) – Display Quantitative resources. Default.
 N (No) – Do not display Quantitative resources.

184
Control-M/Analyzer User Guide

Adding Conditions and Resources – The ADD Command


The ADD command adds conditions to the IOA Conditions file and adds resources to the Control-M
Resources file. Type this command in the COMMAND field, and press Enter. The format of the command
is
ADD type
In this command format, type is one of the following:
 COND – Add a prerequisite condition. Special care must be taken when adding prerequisite
conditions, because added conditions can trigger job submission.
 RESOURCE/RES – (Where Control-M is active) Add a Quantitative resource. Only authorized personnel
should add Quantitative resources.
 Control/CON – (Where Control-M is active) Add a Control resource. A Control resource entry may be
added manually even if a job is holding the resource. Only authorized personnel should add Control
resources.
When the ADD command is entered, an appropriate window is opened. The window illustrated in
Figure 85 opens when ADD COND is entered.
Figure 85 IOA Conditions/Resources ADD COND Window
-------------------------- IOA CONDITIONS/RESOURCES ------------------------(4)
COMMAN +---------------------------------------------------------+ L ===> CRSR
PREFIX | PLEASE FILL IN COND NAME, DATE AND PRESS ENTER | 0909 - 0909
OPT TY | | BA DATE
CO | NAME ===> DDMM ===> | 00)
RE | |
RE +---------------------------------------------------------+
RE
RESOURCE TAPEP 01 U 0002 (00091)
RESOURCE CPU1 01 U 0002 (00091)
RESOURCE CPU2 01 U 0003 (00092)
RESOURCE TAPEP 01 R 0002 1 (00093)
COND BR-BRIVPCC-ENDED-OK 0909
COND BR-BRCC0001-ENDED-OK 0909
COND BR-BRCC0002-ENDED-OK 0909
COND BR-BRCC0003-ENDED-OK 0909
COND BR-BRCCIND-ENDED-OK 0909
COND BR-BRUPDT02-ENDED-OK 0909
COND BR-BRREP001-ENDED-OK 0909
COND BR-BRREP002-ENDED-OK 0909
COND GL-GLINP001-ENDED-OK 0909
COND EBD-APPL-STARTED 0909
COND CICS-PROD-IS-UP STAT
OPTIONS: D DELETE C CHANGE COMMANDS: ADD 14.07.08

Fill in the window fields as described in Table 106 according to the specified ADD command:

185
Control-M/Analyzer User Guide

Table 106 IOA Conditions/Resources ADD Command Formats

Field Description

ADD COND Specify the name of the prerequisite condition. The current working
date is displayed as the default date. This date can be modified.

ADD RESOURCE or Enter the name of the Quantitative resource and the quantity to be
ADD RES added. (Where Control-M is active)

ADD CONTROL or Enter the name of the Control resource and the control type
ADD CON (E – Exclusive; S – Shared). (Where Control-M is active)

Note: If a Control resource is manually added with a type of


E (Exclusive), no jobs in WAIT SCHEDULE status that require this
resource are submitted.
If a Control resource is manually added with a type of S (Shared),
no jobs in WAIT SCHEDULE status that require exclusive access to
this resource are submitted.

After filling in the window, press Enter to add the condition or resource.
Note: If a Control resource is manually added with a type of E (Exclusive), no jobs in WAIT SCHEDULE
status which require this resource are submitted. If a Control resource is manually added with a type of
S (Shared), no jobs in WAIT SCHEDULE status which require exclusive access to this resource are
submitted.
To close the window without adding the condition or resource, press the RESET key (PF04/PF16).

Options of the IOA Conditions/Resources Screen


The options described in Table 107 can be specified for conditions and resources by typing the option in
the OPT field to the left of the resource or condition name and pressing Enter.
Table 107 Options of the IOA Conditions/Resource Screen

Option Description

D (DELETE) Delete a condition or resource from the list. The event is recorded in
the IOA Log file.

C (CHANGE) (At sites where Control-M is active) Change the maximum available
quantity of a Quantitative resource. The event is recorded in the
IOA Log file.

These options are discussed in detail on the following topics.


Deleting Conditions and Resources — The DELETE Option
To delete conditions or resources, type D (Delete) in the OPT field to the left of the conditions and
resources being deleted and press Enter.
A confirmation window may be displayed, depending on User profile customization.

186
Control-M/Analyzer User Guide

 By default, conditions and resources are deleted without confirmation from the user.
 The User profile can be customized to display a confirmation window with an arrow pointing to a
delete request (beginning with the first request).
Figure 86 IOA Conditions/Resources DELETE Confirmation Window
-------------------------- IOA CONDITIONS/RESOURCES ------------------------(4)
COMMAND ===> SCROLL ===> CRSR
PREFIX ===> COND Y CONTROL Y RES Y STAT Y DATE 0909 - 0909
OPT TYPE CONDITION/RESOURCE IOAID USE QUANTITY MAX *P RBA DATE
COND SALARY-PRSL01A-OK 0909
COND SALARY-PRSL002-OK +----------------------+
COND SALARY-PRSL003-OK | CONFIRM |
D COND CBT-TAPE-ARRIVED <---------| ASK FOR EACH ONE Y |
D COND KPL-PRKPL03-OK +----------------------+
COND KPL-PRKPL04-OK 0909
======== >>>>>>>>>>>>>>>> B O T T O M O F L I S T <<<<<<<<<<<<<<<< ========

OPTIONS: D DELETE C CHANGE COMMANDS: ADD 18.48.12

If a confirmation window is displayed, fill in the window as described in Table 108 and press Enter.
Table 108 IOA Conditions/Resources DELETE Confirmation Window Options

Option Description

CONFIRM Whether to process the delete request. Valid values are:


 Y (Yes) – Process the request.
 N (No) – Cancel the request.

ASK FOR EACH ONE This line is displayed only if more than one delete is requested. It
determines whether individual confirmation is required for each
delete request. Valid values are:
 Y (Yes) – Individual confirmation is required for each delete
request. The specified CONFIRM value applies only to the
current order or request.
 N (No) – Individual confirmation is not required for each delete
request. The specified CONFIRM value is applied to all delete
requests. (If CONFIRM is Y, all delete requests are processed; if
CONFIRM is N, no delete request is processed.)

Changing the Quantity of a Resource – The CHANGE Option (Available only if Control-M is active)
To request a change to the maximum available quantity of a resource, type C (Change) in the OPT field
to the left of the resource and press Enter. The window illustrated in Figure 87 is opened.

187
Control-M/Analyzer User Guide

Figure 87 IOA Conditions/Resources CHANGE Option Window


-------------------------- IOA CONDITIONS/RESOURCES ------------------------(4)
COMMAN +---------------------------------------------------------+ L ===> CRSR
PREFIX | PLEASE FILL IN QUANT RES NAME, COUNT AND PRESS ENTER | 0909 - 0909
OPT TY | | BA DATE
CO | NAME ===> TAPEP COUNT ===> | 000)
C RE | |
RE +---------------------------------------------------------+
RE
RESOURCE TAPEP 01 U 0002 (00091)
RESOURCE CPU1 01 U 0002 (00091)
RESOURCE CPU2 01 U 0003 (00092)
RESOURCE TAPEP 01 R 0002 1 (00093)
COND BR-BRIVPCC-ENDED-OK 0909
COND BR-BRCC0001-ENDED-OK 0909
COND BR-BRCC0002-ENDED-OK 0909
COND BR-BRCC0003-ENDED-OK 0909
COND BR-BRCCIND-ENDED-OK 0909
COND BR-BRUPDT02-ENDED-OK 0909
COND BR-BRREP001-ENDED-OK 0909
COND BR-BRREP002-ENDED-OK 0909
COND GL-GLINP001-ENDED-OK 0909
COND EBD-APPL-STARTED 0909
COND CICS-PROD-IS-UP STAT
OPTIONS: D DELETE C CHANGE COMMANDS: ADD 14.07.08

The NAME value in the window is protected and cannot be changed.


The COUNT parameter consists of two values: sign and quantity. Fill in the COUNT parameter as
described in Table 109 and press Enter.
Table 109 COUNT Parameter Values

Value Description

sign Valid values are (one character):


 + (Plus) – Add the selected quantity to the current maximum
available quantity to give a new maximum available quantity.
 - (Minus) – Subtract the selected quantity from the current
maximum available quantity to give a new maximum available
quantity.
 ' ' (Blank) – Set the maximum available quantity to the selected
quantity.

quantity Quantity to be used to adjust the maximum quantity of the resource


(four digits) according to the specified sign. Leading zeros are
required.

188
Control-M/Analyzer User Guide

IOA Manual Conditions Screen


The IOA Manual Conditions screen displays a list of prerequisite conditions that must be confirmed
manually by operations personnel.
The list of manual conditions is created by the IOALDNRS utility. This utility is described in the
INCONTROL for z/OS Utilities Guide. This utility is intended for use at sites where Control-M or Control-D
(or both) are installed.
The utility scans the jobs in the Control-M Active Jobs file, and the missions in the Control-D Active
Missions file, for all conditions requested in IN statements that
 are not resolved by an OUT statement
 are not resolved by ON PGMST or DO COND statements
 do not exist in the IOA Conditions file
The utility automatically places the conditions conforming to the above criteria into the IOA Manual
Conditions file. This file is used as a checklist for manual operations that operations personnel are
expected to perform.
To enter the IOA Manual Conditions screen, select Option 7 on the IOA Primary Option menu.
Figure 88 IOA Manual Conditions Screen
--------------------------- IOA MANUAL CONDITIONS --------------------------(7)
COMMAND ===> SCROLL ===> CRSR
PREFIX ===> PENDING Y ADDED Y STAT Y DATE 0909 - 0909
OPT TYPE CONDITION DATE ADDED
COND USR-GOT-TAX-TAPE 0909
COND DBA-RUN-UPDATE 0909 Y
COND OP-EXTERNAL-TAPE-OK 0909 Y
COND USR-GOT-BANK-TAPE 0909
COND OP-SHUT-THE-SYSTEM 0909
COND DBA-START-MPMXXX 0909
COND USR-GOT-SALARY-TAPE 0909 Y
COND OP-COMMUNICATION-DOWN 0909
======== >>>>>>>>>>>>>>>> B O T T O M O F L I S T <<<<<<<<<<<<<<<< ========

OPTIONS: A ADD TO COND/RES LIST (SCREEN 4) E ERASE COMMANDS: NEW 18.33.47

To exit the IOA Manual Conditions screen, press END (PF03/PF15).

189
Control-M/Analyzer User Guide

Fields of the IOA Manual Conditions Screen


The information displayed on each screen line is described in Table 110.
Table 110 Fields of the IOA Manual Conditions Screen

Field Description

OPT Option to be activated on the condition.

TYPE Type of condition, meaning, COND for prerequisite condition.

CONDITION Condition name

DATE Date reference of prerequisite condition. Format is either mmdd or


ddmm depending on the site standard, or the date value STAT.

ADDED Indicates whether the condition has been manually added to the
IOA Conditions file. Valid values are:
 Y (Yes) – The condition has been added
 N (No) – The condition has not been added

Specifying Retrieval Criteria


You can control the type and amount of information displayed in the screen by specifying retrieval criteria.
Table 111 Retrieval Criteria for IOA Manual Conditional Screen

Criteria Description

PREFIX prefix Limits the display to conditions with the selected prefix. Default:
Blank (no limit).
To display only those conditions containing a specific string, enter
the string preceded by an *.
Example:
If *OK is entered, the following conditions are included in the
display:
UPDATE-ENDED-OK
OK-RUN
OK

190
Control-M/Analyzer User Guide

Criteria Description

PENDING Determines whether conditions not yet added are displayed. Valid
values are:
 Y (Yes) – Display pending conditions
 N (No) – Do not display pending conditions

ADDED Determines whether added conditions are displayed. Valid values


are:
 Y (Yes) – Display added conditions
 N (No) – Do not display added conditions

STAT Determines whether prerequisite conditions with a date value of


STAT are displayed. (Applies only if Y is specified for COND.) Valid
values are:
 Y (Yes) – Display prerequisite conditions with a date value of
STAT
 N (No) – Do not display prerequisite conditions with a date
value of STAT

DATE from – to Limits the display of prerequisite conditions to the specified date
range. Valid values are:
 from – Earliest date in the date range, in mmdd or ddmm
format (depending on the site standard). The default value is
three days prior to the current date.
 to – Latest date in the date range, in mmdd or ddmm format
(depending on the site standard). The default value is the
current date.

191
Control-M/Analyzer User Guide

Adding a New Prerequisite Condition – NEW COND Command


To add a prerequisite condition to the IOA Manual Conditions file, type NEW COND in the COMMAND
field and press Enter. A window is opened.
Figure 89 IOA Manual Conditions Screen NEW COND Window
--------------------------- IOA MANUAL CONDITIONS --------------------------(7)
COMMAN +---------------------------------------------------------+ L ===> CRSR
PREFIX | PLEASE FILL COND NAME AND DATE AND PRESS ENTER | 0909 - 0909
OPT TY | |
CO | NAME ===> MMDD ===> |
CO | |
CO +---------------------------------------------------------+
CO
COND OP-SHUT-THE-SYSTEM 0909
COND DBA-START-MPMXXX 0909
COND USR-GOT-SALARY-TAPE 0909 Y
COND OP-COMMUNICATION-DOWN 0909
======== >>>>>>>>>>>>>>>> B O T T O M O F L I S T <<<<<<<<<<<<<<<< ========

OPTIONS: A ADD TO COND/RES LIST (SCREEN 4) E ERASE COMMANDS: NEW 18.33.47

In the NAME field of the window, type the name of the condition to be added. If the condition has a date
other than the current working date, enter the date in the date field of the window, in the format DDMM
or MMDD, depending on the site standard.
 To add the condition, press Enter.
 To close the window without adding the condition, press RESET (PF04/PF16).
Note: Adding a new condition to the IOA Manual Conditions file does not affect the IOA Conditions file.

192
Control-M/Analyzer User Guide

Options of the IOA Manual Conditions Screen


To add a condition to the IOA Conditions file, or to erase a condition from the IOA Manual Conditions file,
type the appropriate option in the OPT field to the left of the condition name and press Enter. Valid
options are described in Table 112.
Table 112 Options of the IOA Manual Conditions Screen

Option Description

A (ADD) Add the condition to the IOA Conditions file (screen 4), and mark it
"Added" (Y) in the IOA Manual Conditions file. The event is recorded
in the IOA Log file.

E (ERASE) Erase (Delete) a condition from the IOA Manual Conditions file. This
does not affect the IOA Conditions file. This option is discussed in
more detail below.

Erasing (Deleting) Conditions


To erase prerequisite conditions, type E in the OPT field to the left of the condition names being erased
and press Enter.
A confirmation window may be displayed, depending on User Profile customization:
 By default, conditions are deleted without confirmation from the user.
 If, however, the User profile member has been customized accordingly, a confirmation window is
displayed with an arrow pointing to an erase request (beginning with the first request).
Figure 90 IOA Manual Conditions Screen ERASE Confirmation Window
--------------------------- IOA MANUAL CONDITIONS --------------------------(7)
COMMAND ===> SCROLL ===> CRSR
PREFIX ===> PENDING Y ADDED Y STAT Y DATE 0909 - 0909
OPT TYPE CONDITION +——————————————————————+
E COND USR-GOT-TAX-TAPE <—————————| CONFIRM (Y/N) |
COND DBA-RUN-UPDATE +——————————————————————+
COND OP-EXTERNAL-TAPE-OK 0909 Y
COND USR-GOT-BANK-TAPE 0909
COND OP-SHUT-THE-SYSTEM 0909
COND DBA-START-MPMXXX 0909
COND USR-GOT-SALARY-TAPE 0909 Y
COND OP-COMMUNICATION-DOWN 0909
======== >>>>>>>>>>>>>>>> B O T T O M O F L I S T <<<<<<<<<<<<<<<< ========

OPTIONS: A ADD TO COND/RES LIST (SCREEN 4) E ERASE COMMANDS: NEW 11.30.0 2

193
Control-M/Analyzer User Guide

If a confirmation window is displayed, fill in the window as described in Table 113 and press Enter:
Table 113 Fields of the IOA Manual Conditions Screen ERASE Confirmation Window

Fields Description

CONFIRM Indicates whether to process the erase (delete) request. Valid


values are:
 Y (Yes) – Process the request.
 N (No) – Cancel the request.

ASK FOR EACH ONE This line is displayed only if more than one erase is requested. It
determines whether individual confirmation is required for each
erase request. Valid values are:
 Y (Yes) – Individual confirmation is required for each erase
request. The selected CONFIRM value applies only to the
current order or request.
 N (No) – Individual confirmation is not required for each erase
request. The selected CONFIRM value is applied to all erase
requests. If CONFIRM is Y, all erase requests are processed; if
CONFIRM is N, no erase request are processed.

194
Control-M/Analyzer User Guide

IOA Log Facility


The IOA Log facility places automatically generated messages, which record every significant event in the
life of a job, rule or mission, in the IOA Log file. Significant events recorded in the IOA Log file include
normal processing occurrences, such as job submitted, as well as error conditions encountered during
processing, such as job abends. Shout facility notifications and user remarks may also be recorded in the
IOA Log file.

IOA Log Screen


The IOA Log screen enables you to view the information contained in the Log file. To enter the IOA Log
screen, select Option 5 on the IOA Primary Option menu. Upon entry, the screen displays the most recent
messages currently in the IOA Log file.
Figure 91 IOA Log Screen
FILTER: ---------------- IOA LOG -------------------------------(5)
COMMAND ===> SCROLL===> CRSR
SHOW LIMIT ON ==> DATE 060601 - 060601
DATE TIME ODATE USERID CODE -------- M E S S A G E ------------------
060601 092144 060601 M22 SPY254I JOB CT085955 CT085955/01835 SCANNED
060601 092144 060601 M22 SEL208I JOB CT085955 CT085955/01835 ENDED "OK"
060601 092150 060601 M22 SPY254I JOB CT085956 CT085956/01836 SCANNED
060601 092150 060601 M22 SEL208I JOB CT085956 CT085956/01836 ENDED "OK"
060601 092156 060601 IVP SPY254I JOB BRIVPCC BRIVPCC /01843 SCANNED
060601 092157 060601 IVP SEL208I JOB BRIVPCC BRIVPCC /01843 ENDED "OK"
060601 092157 060601 DBA CTM659I FREE OF TASK BRCC0001 ODATE 060601
PERFORMED
060601 092201 060601 M22 SPY281I JOB INTR0004 INTR0004/04371 START
98253.1316 STOP 98253.1316 CPU 0MIN
00.04SEC SRB 0MIN 00.00SEC 0.19
060601 092201 060601 M22 SPY254I JOB INTR0004 INTR0004/04371 SCANNED
060601 092201 060601 M22 SEL206W JOB INTR0004 INTR0004/04371 ABENDED CC
SB37 STEP STEP01
060601 092201 060601 M22 SEL219I JOB INTR0004 INTR0004/04371 ENDED "NOT
OK"
060601 092208 060601 IVP SEL203I JOB BRCC0001 ELIGIBLE FOR RUN
060601 092208 060601 IVP SUB133I JOB BRCC0001 BRCC0002/01958 SUBMITTED
060601 092208 060601 IVP SEL203I JOB BRCC0002 ELIGIBLE FOR RUN
CMDS: SHOW, GROUP, CATEGORY, SHPF 09.43.00

To return to the IOA Primary Option menu, press END (PF03/PF15).

195
Control-M/Analyzer User Guide

Fields of the IOA Log Screen


Table 114 Fields of the IOA Log Screen

Field Description

SHOW LIMIT ON Identifies which selection criteria other than yes or no were entered
in the IOA Log Show Screen window (USERID, MEM/MIS, JOBNAME,
CATEGORY, GROUP). For more information, see Filtering the IOA
Log Screen Display (on page 198).

DATE Date on which the message was issued.

TIME Time at which the message was issued.

ODATE Original scheduling date of the job associated with the message.
Format is mmddyy, ddmmyy or yymmdd, depending on the site
standard.

Note: When the display type is set to RBA display using the
DISPLAY command, the Relative Byte Address (RBA) of the
message within the IOA Log file is displayed instead of the ODATE.
For more information on changing the screen display, see Changing
IOA Log Screen Display Types (on page 197).

USERID User ID of the job issuing the message, or user ID of the user
writing to the log.

CODE IOA message code.

MESSAGE Text of the message. If the message is longer than the space
available on the screen, the message is split and continues on the
following line. Messages relating to a job have the following format:
tasktype memname jobname/jobid message

fromdate – todate Log information displayed in the screen can be limited to the
specified date range in mmddyy, ddmmyy or yymmdd format,
depending on the site standard. If the DATE or the ODATE value for
a message is in the range selected, the message is included in the
IOA Log display. Valid values are:
 fromdate – Earliest date in the date range.
 todate – Latest date in the date range.

196
Control-M/Analyzer User Guide

Commands of the IOA Log Screen


The following commands can be entered in the COMMAND field.

Changing IOA Log Screen Display Types


While in the IOA Log screen, the display type can be changed through the DISPLAY command. The
format of the command is:
DISPLAY x
In this command format, x is a 1-character code that identifies the desired display type. DISPLAY can be
abbreviated DI.
Note: For a list of display types, enter DISPLAY ? to show the Display Options window. To select a
display type in the window, type S in the Option field next to the ID. To exit the window without selecting
a display type, press the END key (PF03/PF15).
Example
DI B
displays the No Reverse display.
Valid predefined displays are described in Table 115.
Table 115 IOA Log Screen Predefined Display Types

Display Description

A Show RBA (Relative Byte Address) display (displays the RBA of the
message within the IOA Log file in place of the ODATE).

D Default display.

B No Reverse display (display is in No Reverse mode).

Uppercasing and lowercasing of variables’ values


While in the IOA Log Screen, uppercase or lowercase mode can be set using the CAPS command. Format
of the command is:
CAPS [{ON | OFF}]
In this command:
 CAPS ON – Forces all user entries to be saved and displayed in uppercase characters, regardless of
the case in which they were entered. Default.
 CAPS OFF – Enables certain user entries to be saved and displayed in lowercase characters.
 CAPS – Indicates whether CAPS ON or CAPS OFF mode is active.
Note: Name of variables do not support lowercase characters.

197
Control-M/Analyzer User Guide

Filtering the IOA Log Screen Display


Screen filters can be used to filter the IOA Log screen display.
A filter consists of a set of record selection criteria (selection fields and their values). Only records that
conform to the selection criteria specified in the filter are displayed on the screen.
The INCONTROL administrator can predefine filters and place them in the General profile.
Each user can activate an existing filter in the IOA Log screen by entering the SHOW command in the
COMMAND line of the IOA Log screen.
Each user can define multiple filters for the screen, through the IOA Log Show Screen window, which is
described in "Fields of the IOA Log Show Screen Window" under IOA Log Show Screen Window (on page
199). User-defined filters belong to, are assigned names by, and can only be activated by, the user who
defined them. They are stored in the user profile.
You can see the list of all available filters by opening the Display Filters window.
A predefined default filter (DEFAULT) is defined for the IOA Log screen. Site-defined defaults determine
whether the last filter used or the DEFAULT filter is activated upon reentry to the IOA Log screen.
Activating an existing filter in the IOA Log screen
The SHOW command can be used to activate an existing filter when you know the name of the filter.
 To activate an existing filter in the IOA Log screen, enter the SHOW command in the COMMAND field,
as follows:
SHOW name
In this command, name is the name of the filter to be activated.
 To activate the DEFAULT filter, use DEFAULT as the name of the filter.

Display Filters Window


When you do not know the name of a filter, you can still activate a filter from the list of available filters by
opening the Display Filters window. This window displays the list of all available filters. These include
Global filters that are available to all users, as well as user-defined filters that are only available to the
individual user. You can activate a filter from the Display Filters window, or switch to the IOA Log Show
Screen window, where you can edit or define a filter.
To enter the Display Filters window, type SHOW ? in the COMMAND field of the IOA Log screen and
press Enter.

198
Control-M/Analyzer User Guide

Figure 92 IOA Log Screen Display Filters Window


FILTER: DEFAULT ---------------- IOA LOG ------------------------------(5)
COMMAND ===> SCROLL===> CRSR
SHOW LIMIT ON ==> DATE 060601 - 060601
DATE TIME ODATE USERID CODE ------ M E S S A G E --------------------
060601 092144 060601 M22 SPY254I JOB CT085955 CT085955/01835 SCANNED
060601 092144 060601 M22 SEL208I JOB CT085955 CT085955/01835 ENDED "OK"
0 +-----------------------------------+ B CT085956 CT085956/01836 SCANNED
0 | DISPLAY FILTERS | B CT085956 CT085956/01836 ENDED "OK"
0 | CMD ==> SCROLL==> CRSR | B BRIVPCC BRIVPCC /01843 SCANNED
0 | O NAME DESCRIPTION | B BRIVPCC BRIVPCC /01843 ENDED "OK"
0 | CONFIRM | EE OF TASK BRCC0001 ODATE 080800
| DEL | RFORMED
0 | END | B INTR0004 INTR0004/04371 START
| ENDNOTOK | 253.1316 STOP 98253.1316 CPU 0MIN
| ENDOK | .04SEC SRB 0MIN 00.00SEC 0.19
0 | EXEC | B INTR0004 INTR0004/04371 SCANNED
0 | LATE | B INTR0004 INTR0004/04371 ABENDED CC
| WAIT | 37 STEP STEP01
0 | ECSALL | B INTR0004 INTR0004/04371 ENDED "NOT
| =========>>> BOTTOM <<<========== | "
0 | | B BRCC0001 ELIGIBLE FOR RUN
0 | OPTIONS S SELECT E EDIT | B BRCC0001 BRCC0002/01958 SUBMITTED
0 +-----------------------------------+ B BRCC0002 ELIGIBLE FOR RUN
CMDS: SHOW, GROUP, CATEGORY, SHPF 09.43.00

Fields of Display Filters Window


The Display Filters window contains the fields described in Table 116.
Table 116 Fields of the Display Filters Window

Field Description

NAME Name of the filter as it appears in the General or user profile.

DESCRIPTION Description of the filter.

Options of the Display Filters Window


To request one of the following options, type the option in the OPT field to the left of the filter name and
press Enter.

IOA Log Show Screen Window


The IOA Log Show Screen window in the IOA Log screen enables you to create or modify a filter.
 To open an existing filter for editing, enter the following command:
SHOW filtername EDIT
where filtername is the name of the filter to be displayed in the IOA Log Show Screen window.

199
Control-M/Analyzer User Guide

 To edit the currently active filter, it is not necessary to enter the name of the filter or the EDIT
keyword. Enter the SHOW command in the COMMAND field, or press PF02/PF14. The IOA Log
Show Screen window illustrated in Figure 93 is displayed.
Figure 93 IOA Log Screen Show Screen Filters Window
FILTER: DEFA +-------------------- IOA LOG SHOW SCREEN -------------------(5)
COMMAND ===> | FILTER SAVE (Y/N) |
SHOW LIMIT O | |
DATE TIME | |
080800 21354 | |
| |
080800 22040 | |
080800 22040 | |
080800 22040 | CB : RUNTIME SHOUT DAILY GENERAL STATISTICS |
| Y Y Y Y Y |
080800 22040 | |
080800 22040 | |
080800 22040 | CODE |
| URGENCY: REGULAR Y URGENT Y VERY-URGENT Y |
080800 23034 | TASK TYPE CM: JOB CYC EMR STC CST EST ECJ ECS WRN GRP |
080800 23040 | Y Y Y Y Y Y Y Y Y Y |
080800 23040 | CD: REP PRT BKP/MIG RST EMR NOEMR CYC NOCYC |
080800 23040 | Y Y Y Y Y Y Y Y |
| USERID N54A |
080800 23040 | MEM/MIS MIGDASD |
080800 23040 | JOBNAME |
080800 23040 | CATEGORY |
| GROUP |
CMDS: SHOW, +--------------------------------------------------------------+

 To create a new filter, open any existing filter and enter a new name and description in the FILTER
and DESC fields (described in "Fields of the IOA Log Show Screen Window," below).
Fields of the IOA Log Show Screen Window
The IOA Log Show Screen window contains the fields described in Table 117.

200
Control-M/Analyzer User Guide

Table 117 Fields of the IOA Log Show Screen Window

Field Description

FILTER User-assigned name of the filter. The name entered in the FILTER
field can be modified.
If changes to a filter have not been saved, an asterisk is displayed
to the right of the filter name. For more information, see Closing the
IOA Log Show Screen Window (on page 204).

SAVE (Y/N) Specifies whether to save modifications to the filter upon closing the
window.

DESC User-defined description of the filter. The description entered here


appears next to the name in the Displaying Filters window.

Note: The INCONTROL administrator can limit which installed INCONTROL products and options each
user may access. However, because all INCONTROL products and the messages they issue are integrated,
it may be important for users to see the messages of products and options to which they have no access.
Therefore, the types of messages for all INCONTROL products are listed in the IOA Log Show Screen
window, and by default, the messages of all installed products are listed in the IOA Log screen.
Fields that define the selection criteria to be applied to the screen are described below. Fill in the selection
criteria as necessary.
Note: The selection criteria marked with the P symbol act on a prefix basis. For example, typing CTB in
the CODE field causes the retrieval of all IOA Log file messages that start with CTB.

201
Control-M/Analyzer User Guide

Table 118 IOA Log Screen Show Filters Window Selection Criteria

Criteria Description

CB message type To limit the type of log messages displayed, specify Y (Yes) or N
(No) under the desired message type. Valid message type codes:
 RUNTIME – Messages related to balancing activities produced
by the Control-M/Analyzer Runtime Environment.
 DO SHOUT – Messages written to the IOA Log file by the DO
SHOUT parameter. For more information, see DO SHOUT:
Automated Balancing Statement (on page 421).
 DAILY – Mission related messages ordered by the New Day
procedure.
 GENERAL – General messages on Control-M/Analyzer operation.
 STATISTICS – Statistical information on Control-M/Analyzer
operation.

Note: Selection criteria identified by "CB message type" are specific to Control-M/Analyzer.
Other selection criteria, such as those described below, are primarily applicable to other
INCONTROL products, but may also be available to Control-M/Analyzer.

CODEH Show only IOA Log file messages with the specified message IDs or
prefixes. A maximum of six message IDs or prefixes can be
specified.

URGENCY Mark Y (Yes) or N (No) to specify the desired urgency of messages.


Urgent and very urgent messages are highlighted.

USERIDH Show only messages of the specified user IDs. A maximum of five
user IDs can be specified.

Note: The MEM/MIS, JOBNAME, CATEGORY, and GROUP selection criteria (described
below) only affect the display of messages related to a mission. Messages not related to a
mission are not affected by these selection criteria and are displayed unless suppressed by
other selection criteria.

MEM/MISH Limit displayed messages to the specified member or mission


names. A maximum of five member or mission names can be
specified. Messages not related to a mission are not affected by this
show limit.

JOBNAMEH Limit displayed messages to the specified job names. A maximum of


five job names can be specified. Messages not related to a job are
not affected by this show limit.

202
Control-M/Analyzer User Guide

Criteria Description

CATEGORY Limit displayed messages to the specified categories. A maximum of


two categories can be specified. Messages not related to a mission
are not affected by this show limit.

GROUPH Limit displayed messages to the specified groups. A maximum of


four groups can be specified. Messages not related to a mission are
not affected by this show limit.

IOA Log Show Screen window (at Sites Where Multiple IOA Products Are
Active)
The IOA Log Show Screen window displays different selection criteria depending on which INCONTROL
products are operational at your site.
The IOA Log Show Screen window at sites where all INCONTROL products are active is illustrated in
Figure 94.
Figure 94 IOA Log Show Screen Window at Sites where Multiple INCONTROL Products
are Active
FILTER: DEFA +-------------------- IOA LOG SHOW SCREEN -------------------(5)
COMMAND ===> | FILTER SAVE (Y/N) |
SHOW LIMIT O | CM : D JOB M JOB SHOUT USER GENERAL D INT M INT STAT |
DATE TIME | Y Y Y Y Y N N N |
060800 21354 | CO+CMEM: GENERAL SHOUT JOBS GENERAL W PIPE W JOB W |
| Y Y Y |
060601 22040 | CD+CV : SBSYS REP MIS SHOUT USER GENERAL DAILY MONIT STAT |
060601 22040 | Y Y Y Y Y Y N N N |
060601 22040 | CB : RUNTIME SHOUT DAILY GENERAL STATISTICS |
| Y Y Y Y Y |
060601 22040 | CT : GENERAL SHOUT REAL-TIME UTILITIES |
060601 22040 | Y Y Y Y |
060601 22040 | CODE |
| URGENCY: REGULAR Y URGENT Y VERY-URGENT Y |
060601 23034 | TASK TYPE CM: JOB CYC EMR STC CST EST ECJ ECS WRN GRP |
060601 23040 | Y Y Y Y Y Y Y Y Y Y |
060601 23040 | CD: REP PRT BKP/MIG RST EMR NOEMR CYC NOCYC |
060601 23040 | Y Y Y Y Y Y Y Y |
| USERID N54A |
060601 23040 | MEM/MIS MIGDASD |
060601 23040 | JOBNAME |
060601 23040 | CATEGORY |
| GROUP |
CMDS: SHOW, +--------------------------------------------------------------+

The Control-M/Analyzer selection criteria are described in Table 118 in IOA Log Show Screen Window (on
page 199). For descriptions of the selection options for other INCONTROL products, see the user guides
of the respective products.
The INCONTROL administrator can limit which installed INCONTROL products and options each user can
access. However, because all INCONTROL products and the messages they issue are integrated, it may
be important for users to see the messages of products and options to which they have no access.
Therefore, the types of messages for all INCONTROL products are listed in the IOA Log Show Screen
window, and by default, the messages of all installed products are listed in the IOA Log screen.

203
Control-M/Analyzer User Guide

Closing the IOA Log Show Screen Window


You can activate an edited filter with or without saving changes, depending on the value you type in the
SAVE field, as follows:
 To activate and save the filter, type Y (Yes) in the SAVE field. Changes to the filter are permanently
saved.
 To activate the filter without saving it, type N (No) in the SAVE field. Changes are kept in memory
only, but are not saved.
After entering a value in the SAVE field, press one of the keys described in Table 119.
Table 119 IOA Log Show Screen window - Closing Values

Key Description

Enter Filtering begins with the first message currently displayed in the
screen and continues downward.

PF07 (UP) Filtering begins with the first message in the IOA Log file and
continues downward.

PF08 (DOWN) Filtering begins with the last message in the IOA Log file and
continues upward.

The window is closed and the filter is activated as defined or modified.


To cancel changes made in the IOA Log Show Screen window, press RESET (PF10/PF22). The changes
are canceled regardless of the value entered in the SAVE field, the window is closed, and the filter that
was previously in effect is restored.
By default, pressing END (PF03/PF15) in the window works like pressing Enter. However, the default
can be modified so that pressing END works like pressing RESET.

IOA Calendar Facility


The IOA Calendar facility enables you to create, view, or modify calendar definitions.
Calendars simplify the scheduling of INCONTROL product jobs, missions, rules, and so on. When a
particular schedule is used in many job scheduling, mission, and/or rule definitions, a calendar can be
defined for that schedule, and the name of that calendar can be specified in all the job, mission, or rule
definitions that use that particular schedule.
For example, calendars may be defined to handle the normal scheduling needs for workdays, holidays,
weekends, beginning of month, end of month, and so on. Exception calendars may also be created.
A calendar definition consists of parameters that specify when scheduling occurs.
Calendar definitions are stored in members. A member usually contains multiple calendar definitions, as
follows:

204
Control-M/Analyzer User Guide

 A member contains the calendars required for a specific type of scheduling need. For example, the
calendar member WORKDAYS may contain the calendar definitions for normal workday scheduling.
 Each calendar definition in that member defines the schedule for a given year. For example, the
calendar member WORKDAYS may contain calendar definitions 2001, 2002, and 2003. Each of those
definitions contains the normal workday schedule for the corresponding year.
The IOA Calendar facility also enables the definition of varied work periods throughout the year, in special
calendars called periodic calendars.
A calendar definition needs to be created only once. Once defined, the definition is saved and used as
necessary for scheduling. Calendar definitions can be modified or deleted as required.
Any number of calendar members can be defined. Calendar members are stored in calendar libraries
(partitioned data sets). Generally one calendar library is defined at time of installation, and referenced by
the DACAL DD statement.
Note: The IOA Calendar facility does not support members that have been compressed using the ISPF
PACK option.

Accessing the IOA Calendar Facility


The IOA Calendar facility contains the screens described in Table 120:
Table 120 IOA Calendar Facility Screens

Screen Description

IOA Calendar Facility Enables specification of parameters that determine which records
entry panel are displayed in subsequent screens.

Calendar List screen Displays the list of calendar members in the selected calendar
library.

Year List screen Displays the list of years for which there is a calendar definition in
the selected calendar member.

Calendar Definition Displays the parameters of the selected calendar for the selected
screen year. This is the main screen of the facility.

To enter the Calendar facility, select Option 8 in the IOA Primary Option menu. The Calendar facility entry
panel is displayed.
Depending on the values entered in the entry panel, you can bypass the Calendar List screen and the
Year List screen.

205
Control-M/Analyzer User Guide

IOA Calendar Facility Entry Panel


The entry panel is displayed upon entering the IOA Calendar facility (option 8 in the IOA Primary Option
menu).
Figure 95 IOA Calendar Facility – Entry Panel
--------------------- IOA CALENDAR FACILITY - ENTRY PANEL ------------------(8)
COMMAND ===>

SPECIFY LIBRARY, CALENDAR, YEAR

LIBRARY ===> IOA.PROD.CAL


CALENDAR ===> (Blank for calendar selection list)
YEAR ===> (Blank for year selection list)

USE THE COMMAND "SHPF" TO SEE PFK ASSIGNMENT 10.58.42

Fields of the IOA Calendar Facility Entry Panel


Fill in the fields described in Table 121 and press Enter.
Table 121 Fields of the IOA Calendar Facility Entry Panel

Field Description

LIBRARY Name of the desired calendar library. Mandatory.


If you make an entry in this field without filling in the CALENDAR
field, the list of calendars in the selected library is displayed in the
Calendar List screen.
If you make an entry in this field, you can restrict the list of
calendars that are displayed by entering in the CALENDAR field part
of a Calendar name together with a mask character or characters (?
and *).

CALENDAR Name of the desired calendar member. Optional.


If an entry is made in this field without filling in the YEAR field, the
list of years in the selected calendar member is displayed in the
Year List screen.

206
Control-M/Analyzer User Guide

Field Description

YEAR Year of the desired calendar definition. Optional.


This field can be used only if a CALENDAR value is also entered. If
specified, the calendar definition is displayed in the Calendar
Definition screen.

Note: If you use the selection list fields, their values are not erased until you exit the entry panel by
pressing END (PF03/PF15).

Calendar List Screen


The Calendar List screen displays a list of calendars (members) in the selected library. This screen can be
entered directly from the entry panel or upon exiting the Year List screen.
By default, only calendar names are listed in the screen. However, if the default has been modified at
time of installation, statistical information is displayed for each calendar name, as illustrated in Figure 96.
Figure 96 Calendar List Screen
CALENDARS IN LIB IOA.PROD.CAL ------------(8.D)
COMMAND ===> SCROLL===> CRSR
OPT NAME ------------ VV.MM CREATED CHANGED SIZE INIT MOD ID
BANKDAYS 01.00 02/01/28 01/06/29 09:50 104 104 0 IOAPROD
DAYSOFF 01.00 02/01/28 01/06/29 09:50 30 30 0 IOAPROD
HOLIDAYS 01.00 02/01/28 01/06/29 09:50 15 15 0 IOAPROD
PERIOD1O 01.00 02/01/28 01/06/29 09:50 45 45 0 IOAPROD
SACAYCLN 01.01 02/01/28 01/11/29 17:43 26 26 0 L3051
SPMONCLN 01.01 02/01/29 01/11/30 15:00 117 104 0 M16A
SPWEKCLN 01.01 02/01/29 01/11/30 15:10 117 104 0 M16A
STOCKDAY 01.00 02/01/30 01/06/31 09:50 45 45 0 IOAPROD
WORKDAYS 01.01 02/01/30 01/11/31 17:43 26 26 0 L3051
======= >>>>>>>>>>>>>>>> NO MORE CALENDARS IN LIBRARY <<<<<<<<<<<<<<<< ======

OPTIONS: S SELECT B BROWSE D DELETE 13.54.14

To return to the entry panel, press END (PF03/PF15).

207
Control-M/Analyzer User Guide

Options of the Calendar List Screen


To request one of the options described in Table 122, type the option in the OPT field to the left of the
calendar names, and press Enter.
Table 122 Options of the Calendar List Screen

Option Description

S (SELECT) Display the list of years for the calendar for any purpose, including
editing or modification. Only one calendar can be selected at a time.

B (BROWSE) Display the list of years for the calendar for browsing. Only one
calendar can be selected at a time.

D (DELETE) Delete the calendar (member) from the library. Multiple calendars
can be selected.

Year List Screen


The screen displays the list of years for which a specified calendar is defined. This screen can be entered
directly through the entry panel or the Calendar List screen, or upon returning from the Year Definition
screen.
Note: If the S (Select) option was entered in the Calendar List screen for a calendar that is currently in
use (selected) by another user, either the Year List screen is not displayed and the Calendar List screen
remains displayed (the default), or the Year list screen is displayed in Browse mode (if a user profile
definition overrides the default). In either case, an appropriate message is displayed.
If a calendar description was defined in the Calendar Definition screen, the definition is displayed to the
right of the year.

208
Control-M/Analyzer User Guide

Figure 97 Year List Screen


LIST OF YEARS IN IOA.PROD.CAL CALENDAR WORKDAYS
COMMAND ===> SCROLL===> CRSR
OPT YEAR ------------------ DESCRIPTION --------------------------------------
2001 REGULAR WORKING DAYS IN 2001
2002 REGULAR WORKING DAYS IN 2002
2003 REGULAR WORKING DAYS IN 2003
2004 REGULAR WORKING DAYS IN 2004
2005 REGULAR WORKING DAYS IN 2005
======= >>>>>>>>>>>>>>>> NO MORE YEARS IN CALENDAR <<<<<<<<<<<<<<<< =====

OPTIONS: S SELECT D DELETE I INSERT W INSERT BY WEEK DAYS C COPY 08.52.54

To return to the Calendar List screen press END (PF03/PF15).

Format of the Year List Screen


Next to each year in the Year list, certain information can be displayed. The type and format of this
information depends on whether the screen is displayed in DESC format or in STAT format:
 In DESC format, the description of the year, taken from the DESC field of the calendar definition, is
displayed. Default.
 In STAT format, the ISPF statistical information for the calendar definition is displayed.
By default, the Year list is displayed in DESC format. To change formats, use the DESC or STAT
commands, described in Table 123.

Commands of the Year List Screen


The commands described in Table 123 can be entered in the COMMAND field of the Year List screen.
Table 123 Commands of the Year List Screen

Command Description

DESC The DESC command displays the calendar description next to the
year. The description is taken from the DESCRIPTION field in the
calendar definition.

STAT The STAT command displays the following ISPF-like statistical


information about the calendar next to the year: version and
modification numbers, creation date, last modification date, and
user ID.

209
Control-M/Analyzer User Guide

Options of the Year List Screen


To request one of the options described in Table 124, type the option in the OPT field to the left of the
year and press Enter.
Note: If the Year List screen is displayed in Browse mode, Options D (Delete), I (Insert), and W (Insert By
Week Days) are not available.
Table 124 Options of the Year List Screen

Option Description

S (SELECT) Display the calendar definition for the specific year.


Parameters can be edited and updated only if the Calendar
Definition screen is not displayed in Browse mode. If the Calendar
Definition screen is displayed in Browse mode, the screen can only
be browsed and parameters cannot be modified.

D (DELETE) Delete the calendar definition for the specified year.

I (INSERT) Insert a new year in the Year List screen and display the Calendar
Definition screen with a predefined year definition for editing. The
predefined calendar definition is defined with the same dates as the
year next to which the I (Insert) request was specified. For more
information, see "Inserting a New Year" below.

W (INSERT BY WEEK Insert a new year in the Year List screen and display the Calendar
DAYS) Definition screen for editing a predefined year definition. The
predefined year definition is defined with the same days of the week
as the year next to which the W (Insert by Week Days) request was
specified. For more information, see "Inserting a New Year." below.

C (COPY) Copy the year to another calendar, as described in Copying Years to


Another Calendar (on page 211). Multiple years can be selected.

Inserting a New Year


All calendar definitions identified in the same Year List usually have the same fixed scheduling pattern.
Often, this scheduling pattern is based either on dates within a month or on days of the week within the
month. For example:
 Calendar QUARTERLY might always indicate scheduling for the last day of March, June, September
and December (that is, a scheduling pattern based on dates).
 Calendar WEEKEND might always indicate scheduling all Saturdays and/or Sundays in each month
(that is, a scheduling pattern based on days of the week).
This scheduling pattern also applies to new calendar definitions resulting from the insertion of a new year
in the Year List screen.

210
Control-M/Analyzer User Guide

When a year is inserted in the Year List, the IOA Calendar facility automatically generates a predefined
calendar definition for the new year, based on the scheduling pattern of the calendar by which the insert
request was specified. This frees the user from having to manually define the new calendar. This
automatically generated calendar definition can be displayed and modified.
Note: The Year list must be kept in ascending order without missing years (for example, 2001, 2002,
2003, 2004, 2005). Each new year must be added at the end of the list.
In calendar definitions, a defined scheduling date is described by both the date (month and day) and the
day of the week. Because a particular date falls on a different day of the week in different years, it is
necessary to indicate whether the scheduling pattern is based on the date or on the days of the week.
This is indicated by the specified insert option.
 To define the calendar with the same scheduling dates (although corresponding days of the week
may vary, for example, calendar QUARTERLY described above), type option I (INSERT).
 To define the calendar so that scheduling takes place on the same weekdays as in the previous
calendar (although the corresponding dates may vary, for example, calendar WEEKEND described
above), type option W (INSERT BY WEEK DAYS).
 If the scheduling pattern is mixed (for example, calendar HOLIDAYS always indicates scheduling on
both January 1 and the first Monday in September), specify the more appropriate option and correct
the new calendar definition manually.

Copying Years to Another Calendar


Years currently displayed in the Year List screen can be copied to another calendar. To copy the desired
years, type option C (COPY) next to each desired year in the screen and press Enter. The window
illustrated in Figure 98 is displayed.
Figure 98 Calendar List Screen Copy Window
LIST OF YEARS IN: IOA.PROD.CAL CALENDAR: CALEN1
COMMAND ===> SCROLL===> CRSR
OPT YEAR -------- DESCRIPTION ------------------------------------------------
2001 REGULAR WORKING DAYS IN 2001
C 2002 REGULAR WORKING DAYS IN 2002
2003 REGULAR WORKING DAYS IN 2003
2004 REGULAR WORKING DAYS IN 2004
+-----------------------------------------------------------+
| |
| SPECIFY DESTINATION LIBRARY,CALENDAR AND RULE NAME |
| |
| LIBRARY : IOA.PROD.CAL |
| CALENDAR: |
| YEAR : 2005 |
| |
| PRESS END/RESET TO CANCEL ENTER TO PERFORM THE COPY |
+-----------------------------------------------------------+

OPTIONS: S SELECT D DELETE I INSERT W INSERT BY WEEK DAYS C COPY 15.37.39

The window contains the fields described in Table 125 (some fields contain default values that can be
modified).

211
Control-M/Analyzer User Guide

Table 125 Fields of the Calendar List Screen Copy Window

Field Description

LIBRARY Library containing the calendar into which the years must be copied.
Must be an existing library. Default: The current library.

CALENDAR Name of the calendar into which the year must be copied.

Note: A year can only be copied to another calendar. It cannot be


copied to its own calendar (even if the year is renamed).
If the selected calendar does not exist in the Calendar List, the
calendar is created when the request is performed.

YEAR Name of the year to be copied. If multiple years are selected, the
window is initially displayed with the first selected year. As each
request is performed or canceled, the next requested year name
appears.

To perform a request, press Enter.


To cancel a request, press END (PF03/PF15) or RESET (PF04/PF16).

Calendar Definition Screen


This screen is used to define, display and modify dates in a calendar for a specific year. This screen can
be entered directly from the entry panel or from the Year List screen.
Figure 99 Calendar Definition Screen
--------------------------- IOA CALENDAR - WEEKDAYS ----------------------(8.Y)
COMMAND ===> SCROLL===> CRSR
YEAR 2002 REGULAR WORKDAYS IN 2002

-----S-------------S-------------S-------------S-------------S-------------S---
1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1
01 Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y
-----S-------------S-------------S-------------S-------------S-------------S---
1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8
02 Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y
-----S-------------S-------------S-------------S-------------S-------------S---
1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1
03 Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y
-----S-------------S-------------S-------------S-------------S-------------S---
1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 +
04 Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y
-----S-------------S-------------S-------------S-------------S-------------S---
1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1
05 Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y
-----S-------------S-------------S-------------S-------------S-------------S---
1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 +
06 Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y
-----S-------------S-------------S-------------S-------------S-------------S---
TYPE Y IN ALL THE EXECUTION DAYS 14.37.10

212
Control-M/Analyzer User Guide

Fields of the Calendar Definition Screen


Table 126 Fields of the Calendar Definition Screen

Field Description

YEAR Year of the calendar. This value can be modified. When modified,
the values indicated for each date in each month (described below)
are shifted to the appropriate day of the week.

description User-supplied, free text description of the calendar. Optional.

month/dates Each month of the year (01 through 12) of the calendar consists of
the following:
 Separator line. Sunday (or Saturday) is marked "S" (according
to the default at your site).
 Month label (01 through 12).
 Date label for the day of the month.
 Updatable field for defining execution dates. Valid values are:
 Y (Yes) – Select the rule on that date.
 N (No) or ' ' (Blank) – Do not select the rule for execution on
that date.
 + – For a relative calendar, select the closest next "date."
 - – For a relative calendar, select the closest previous "date."

Note: A relative calendar is a calendar used in a formula to create


other calendars. It cannot be specified in a DCAL, WCAL, or
CONFCAL field. For details, see the description of the IOABLCAL
utility in the INCONTROL for z/OS Utilities Guide.

213
Control-M/Analyzer User Guide

Periodic Calendars
Some rules must be scheduled periodically, according to schedules that are not easily expressed in terms
of fixed days and dates within months. In these cases, monthly, or even yearly, scheduling definition is
awkward. For example:
 A payroll rule needs to be scheduled every other Wednesday:
• In some months, the rule may be scheduled on the first, third, and even fifth Wednesday in the
month. In other months, it may be scheduled on the second and fourth Wednesday in the month.
• In some years, the rule may be scheduled beginning on the first Wednesday of the year. In other
years, it may be scheduled beginning on the second Wednesday of the year.
 A rule must be scheduled every 25 days, regardless of date. Such a rule is scheduled on different
dates each month and each year.
The IOA Calendar facility provides special calendars, called periodic calendars, to allow specification of
these scheduling requirements. These periodic calendars are very flexible.
To designate a calendar as periodic, you must type reserved string ==PERIODIC== in the first 12
positions of the description field. Any text can be entered in the rest of the description field. This is
illustrated in Figure 100.
Figure 100 Use of Reserved String "==PERIODIC=="
COMMAND ===> SCROLL===> CRSR
YEAR 2002 - ==PERIODIC== GENERAL WORKDAY CALENDAR

The following are characteristics of periodic calendars:


 In a periodic calendar, days are not marked using the letters Y (Yes) or N (No). Instead, a period
identifier is used to mark working days in a period. A period identifier can be any letter from A to Z
(except Y and N), any number from 0 to 9, or any other printable sign. If you need more characters,
use characters falling within the hexadecimal range 4A through F9. All working days within the same
period must be marked using the same period identifier character so that different identifier
characters indicate different periods. Days that are not marked are nonworking days because they do
not belong to any period in this calendar.
 Identifiers from different periods can be interspersed throughout a periodic calendar.
 A periodic calendar can consist of smaller units that do not correspond to regular months, in that they
can be longer or shorter than regular months.
 A periodic calendar can span a period, called a "logical year", which can be longer or shorter than one
regular calendar year.
 When a periodic calendar spans parts of two regular calendar years, special considerations are likely
to arise. For more information, see Special Year-End Handling of Periodic Calendars (on page 215).
 A period can span any number of days, but no more than a preset number of days can elapse after
the appearance of one identifier in a period until the appearance of the next matching identifier in the
same period. After that period expires, the next matching identifier starts a new period.
By default, this period is preset to 33 days. Once the length of the gap between matching identifiers
exceeds 33 days, the period automatically closes.
Note: The length of the default period can be changed from 33 days by the INCONTROL administrator,
using optional Wish WM2888.

214
Control-M/Analyzer User Guide

For more information on the use of periodic calendars, see DAYS: Mission Definition Parameter (on page
542) and WDAYS: Mission Definition Parameter (on page 592).
Examples
The following are examples of periodic calendars:
Figure 101 Periodic Calendar – Example 1
-----S-------------S-------------S-------------S-------------S-------------S--
1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1
12 A A A B A
-----S-------------S-------------S-------------S-------------S-------------S--
1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1
01 B B
-----S-------------S-------------S-------------S-------------S-------------S--

This example contains two periods: A and B.


 Period A starts on December 13 and ends on December 23. During this period, the defined working
days are December 13, December 18, December 20, and December 23.
 Period B spans more than one calendar year. It starts on December 21 and ends on January 24.
During this period, the defined working days are December 21, January 4, and January 24.
Figure 102 Periodic Calendar – Example 2
-----S-------------S-------------S-------------S-------------S-------------S----
1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1
03 B A B A
-----S-------------S-------------S----------0---S-------------S-------------S---
1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 +
04 B
-----S-------------S-------------S-------------S-------------S-------------S--

This example includes a period B that begins on March 9. The last marked working day of the period is
March 21, which is followed by a 33-day gap. Assuming that Wish WM2888 has not been used to alter the
default period of 33 days, period B automatically ends on April 23, and April 24 marks the beginning of a
new period B. If no more B identifiers are added, this new B period ends on May 27.

Special Year-End Handling of Periodic Calendars


On occasion, rules, jobs, or missions may be improperly scheduled if a periodic calendar contains one or
more periods that start in one year and continue into the next year, under the following circumstances:
 If the default gap between occurrences of matching identifiers has been changed from 33 days to a
longer period
and
 The first occurrence of the matching identifier in one logical year falls within the default gap that
began at the last occurrence of the matching identifier in a prior logical year
In this case, the period in the prior logical year overlaps the period in the later logical year, causing a
scheduled rule not to run in the later logical year as expected.
To avoid this problem, remove logical years from periodic calendars as soon as they are no longer
needed.

215
Control-M/Analyzer User Guide

Example
 Logical year FISCAL01 extends from April 1, 2001 through March 31, 2002.
 Logical year FISCAL01 contains a period identified as Period A that has been defined to begin on
December 28, 2001 and to continue through January 15, 2002.
 Logical year FISCAL02 extends from April 1, 2002 through March 31, 2003.
 Logical year FISCAL02 also contains a period identified as Period A, defined to begin on April 20, 2002
and continue through May 3, 2002.
 Rule X is scheduled for the seventh day of Period A in each logical year, through the rule definition
DAYS=D7PA.
In the case of the default gap being 33 days, Rule X runs in January 2002, and again in April 2002, as
expected.
In the case of the default gap being changed from 33 to a longer period, such as 120 days, the first day
of Period A in logical year FISCAL02 occurs less than 120 days after the last appearance of Period A in
logical year FISCAL01. As a result, what appears to be the seventh day in Period A in April 2002 is not
recognized as such, because the "old" Period A overlaps the "new" Period A. Consequently, Rule X does
not run again when the user may have expected it to run.

Deleting Calendars
To delete calendars, type D next to the calendar names in the Calendar List screen and press Enter.
The confirmation window illustrated in Figure 103 is displayed, in sequence, for each calendar selected for
deletion.
Figure 103 Calendar List Screen Delete Confirmation Window
CALENDARS IN LIB IOA.PROD.CAL ------------(8.D)
COMMAND ===> +--------------------------+ SCROLL===> CRSR
OPT NAME --- | CONFIRM DELETE OPTION | E INIT MOD ID
D BANKDAYS <-----------| (Y/N) | 4 104 0 IOAPROD
DAYSOFF +--------------------------+ 0 30 0 IOAPROD
HOLIDAYS 01.00 02/01/28 01/06/29 09:50 15 15 0 IOAPROD
PERIOD1O 01.00 02/01/28 01/06/29 09:50 45 45 0 IOAPROD
D SACAYCLN 01.01 02/01/28 01/11/29 17:43 26 26 0 L3051
SPMONCLN 01.01 02/01/29 01/11/30 15:00 117 104 0 M16A
SPWEKCLN 01.01 02/01/29 01/11/30 15:10 117 104 0 M16A
STOCKDAY 01.00 02/01/30 01/06/31 09:50 45 45 0 IOAPROD
WORKDAYS 01.01 02/01/30 01/11/31 17:43 26 26 0 L3051
======= >>>>>>>>>>>>>>>> NO MORE CALENDARS IN LIBRARY <<<<<<<<<<<<<<<< ======

OPTIONS: S SELECT D DELETE I INSERT W INSERT BY WEEK DAYS C COPY 13.54.14

Type Y (Yes) in the window to delete the calendar.


Type N (No) in the window to cancel the delete request.
Note: If PDSMAN is operational at your site, $$$SPACE members are not deleted.
For each calendar deleted, a message is written to the IOA Log file.

216
Control-M/Analyzer User Guide

Exiting the IOA Calendar Facility


When exiting the IOA Calendar facility, screens are exited in the following sequence:
1. Calendar Definition screen
2. Year List screen
3. Calendar List screen
Note: If the Calendar List screen was bypassed as you entered the IOA Calendar facility (that is, if you
entered a CALENDAR value in the entry panel), the Calendar List screen is not displayed upon exiting the
Year List screen; instead, the entry panel is displayed.

Calendar Facility Entry Panel


The commands and options available when exiting screens depend on the screen being exited and on
whether changes have been made. If changes have been made, the selected exit options and commands
determine whether the changes are saved. Exit options and commands are discussed below on a screen
by screen basis.

Exiting the Calendar Definition Screen


Use any of the commands described in Table 127, or press the corresponding PFKey, to exit the Calendar
Definition screen:
Table 127 Commands for Exiting the Calendar Definition Screen

Command Description

CANCEL Cancel the changes made to the calendar definition and return to
the Year List screen.

Note: The following exit commands retain changes to the calendar definition in memory.
To permanently save the changes to disk, you must also request that the changes be saved
when you exit the Year List screen.

END (PF03/PF15) Keep changes to the calendar definition in memory and exit to the
Enter Year List screen.

NEXTYEAR Keep changes to the calendar definition in memory and display the
(PF11/PF23) next calendar definition in the Year List screen.

PREVYEAR Keep changes to the calendar definition in memory and display the
(PF10/PF22) previous calendar definition in the Year List screen.

217
Control-M/Analyzer User Guide

Exiting the Year List Screen


Press END (PF03/PF15) to exit the Year List screen. If changes made to at least one calendar definition
have been kept in memory or if any changes have been made to the Year List screen, the Exit Option
window is displayed. For more information, see Exiting the Calendar Definition Screen (on page 217).
Figure 104 Year List Screen Exit Option Window
LIST OF YEARS IN IOA.PROD.CAL CALENDAR WORKDAYS
COMMAN +-----------------------------------------------------------+ ===> CRSR
OPT N | PLEASE SELECT EXIT OPTION |
1 | |
1 | SAVE CREATE |
1 | |
====== | LIBRARY IOA.PROD.CAL | << =====
| TABLE WORKDAYS |
| |
+-----------------------------------------------------------+

OPTIONS: S SELECT D DELETE I INSERT W INSERT BY WEEK DAYS C COPY 08.53.50

Fill in the Exit Option window as follows:


 The LIBRARY and TABLE (member) fields indicate the library and member in which the calendar
definitions must be saved. The specified values can be modified (for example, to save the calendar
definitions in a different member).
 To save all changes currently in memory and exit the Year List screen, type Y (Yes) after the word
SAVE or CREATE:
• Type Y after the word SAVE if a member with the same calendar name already exists in the
specified library.
• Type Y after the word CREATE if a member with the same calendar name does not exist in the
specified library.
Note: If you create a new calendar member, the member name does not appear in the Calendar List
screen upon exiting the Year List screen; it first appears when you reenter the Calendar List screen from
the entry panel.
 To cancel changes currently in memory and exit the Year List screen, type N (No) after the word
SAVE or CREATE.
 To close the Exit Option window and remain in the Year List screen (with the changes remaining in
memory), press RESET (PF04/PF16).

Exiting the Calendar List Screen


Press END (PF03/PF15) to exit the Calendar List screen.

218
Control-M/Analyzer User Guide

Exiting the IOA Calendar Facility Entry Panel


Press END (PF03/PF15) to exit the entry panel.

Utilities Under ISPF


Several IOA facilities can only be activated under ISPF. To activate these facilities, select Option 6 on the
IOA Primary Option menu (under ISPF) or invoke the IOAUTIL CLIST from the TSO Command Processor
screen. The IOA Online Utilities menu is displayed.
Note: The INCONTROL administrator can remove user authority to access Option 6 on the IOA Primary
Option menu. In this case, the IOA Online Utilities menu is not displayed.

IOA Online Utilities Menu


Depending on the INCONTROL products that are available at your site, different online utility options are
displayed in the Online Utilities menu. Figure 105 shows the IOA Online Utilities menu that is displayed
when all applicable INCONTROL products are active.
Figure 105 IOA Online Utilities Menu when all INCONTROL Products are Installed
------------------------------ ON-LINE UTILITIES ------------------------------
USERID - N06
TIME - 13:40
TERMINAL - 3278

D1 DECOLLATING - Schedule a Report Decollating Mission


D2 PRINT - Schedule a Printing Mission
D3 BACKUP/MIGRATION - Schedule a Backup/Migration Mission
D4 RESTORE - Schedule a Restore Mission
I1 PREREQ CONDITION - Add/Check/Delete a Prerequisite Condition
M1 JOB ORDER ISSUE - Issue a Job Order
M2 AUTOEDIT SIMUL - Perform an AutoEdit Simulation
M3 SIMUL/TAPE PULL - Prepare Simulation/Tape Pull List Job
M4 PARAM PROMPTING - Parameter Prompting Facilities
M5 QUICK SCHEDULE - Quick Schedule Definition
M6 USER INTERFACE - End-User Job Order Interface
R1 CTM/RESTART SIM - Control-M/Restart Simulation
R2 DATASET CLEANUP - Control-M/Restart Dataset Cleanup
R3 JOB DATASET LIST - Prepare a Job Dataset List
R4 STANDALONE - Control-M/Restart Standalone
T1 CONTROL-M/Tape SIMUL - Simulate Control-M/Tape Rules
X EXIT - Exit This Menu

OPTION ===>

Note: If DOCU/TEXT has also been installed at your site, an additional utility, Option U1, is displayed in
the Online Utilities Menu.
To access an available utility, type the desired option in the OPTION field and press Enter.
If no other BMC products are installed at your site, the only option that is directly available to
Control-M/Analyzer is Option I1, the IOA Utility, which is described on the following pages. For the
descriptions of other utilities on the menu, see the user guides of the relevant products.
Online utility screens utilize standard ISPF profile capabilities.

219
Control-M/Analyzer User Guide

Quick transfer to a utility can be performed by entering =opt from another utility screen, or =6.opt from a
non-utility screen (for example, the IOA Log screen), where opt is the 2-character option identified on the
IOA Online Utilities menu.

I1: Add/Check/Delete a Prerequisite Condition


This utility adds prerequisite conditions to, checks the existence of prerequisite conditions in, and deletes
prerequisite conditions from, the IOA Conditions file.
The Prerequisite Condition Utility screen, illustrated in Figure 106, can be displayed in the following ways:
 Select Option I1 in the Online Utilities menu.
 Invoke the IOACCND CLIST from the TSO Command Processor screen.
Figure 106 Prerequisite Condition Utility Screen
----------------------- PREREQUISITE CONDITION UTILITY ---------------------
COMMAND ===>

FUNCTION ===> ADD (ADD/CHECK/DELETE)

CONDITION NAME ===> SALARY_RPT_OK

Enter either date or STAT:

CONDITION DATE ===> STAT (DDMM OR STAT)

ENTER YES TO CONTINUE ===> YES

To activate the utility, fill in the fields described in Table 128 and press Enter:

220
Control-M/Analyzer User Guide

Table 128 Prerequisite Condition Utility Screen Fields

Field Description

FUNCTION Function to be performed. Valid values are:


 ADD – Add the specified condition to the IOA Conditions file.
 CHECK – Check if the specified condition exists in the IOA
Conditions file.
 DELETE – Delete the specified condition from the IOA Conditions
file.

CONDITION NAME Name of the prerequisite condition (1 through 39 characters) to be


added, checked, or deleted. If CONDITION NAME values contain the
special characters ampersand (&) or apostrophe (‘), they must be
repeated in order to appear on the screen.

CONDITION DATE 4-character date associated with the specified condition. Valid values
are:
 date – Valid date in date in mmdd or ddmm format, depending on
the site standard.
 STAT – Static. Value assigned to conditions that are not
date-dependent, such as DATABASE-OK.

ENTER YES TO Confirmation field to prevent the unintentional addition or deletion of


CONTINUE a condition. When blank, the operation is not performed. Type YES to
add, check or delete the condition.

To exit the screen without activating the utility, press PF03/PF15.

221
3
3
Control-M/Analyzer Variables
This chapter includes the following topics:
 Control-M/Analyzer Variables (on page 223)
• Variable Types (on page 223)
• %% Operator (on page 224)
• Passing Variables to Blocks, Rules and User Routines (on page 224)
 Database Variables (on page 225)
• Variable Generation Attributes (on page 226)
• Accessing Database Variables (on page 233)
 Automatic Database Variable Creation (on page 235)
 Database Variable Definition Screen (on page 236)
 Defining Database Variables (on page 237)
 Database Variable Parameters – Summary (on page 238)
 NAME Basic Parameters (on page 239)
 GROUP Basic Parameters (on page 241)
 CREATED...BY...TYPE: Basic Parameters (on page 243)
 DESC: Basic Parameters (on page 245)
 MAXIMUM ACTIVE GENERATIONS: Generation Parameters (on page 246)
 GEN TYPE: Generation Parameters (on page 248)
 CURRENT ACTIVE GENERATIONS: Generations Parameter (on page 249)
 OLDEST... DATE: Generation Parameters (on page 251)
 LATEST... DATE: Generation Parameters (on page 253)
 TYPE: Validation Parameter (on page 254)
 MASK: Validation Parameters (on page 255)
 AutoEdit Variables (on page 256)
• How AutoEdit Variables Are Used (on page 256)
• Searching for AutoEdit Variables (on page 258)
• Format (on page 258)
• Rules of AutoEdit Variable Substitution (on page 258)
• Assigning AutoEdit Variables With DO SET (on page 259)

222
Control-M/Analyzer User Guide

• Adding AutoEdit Variables to AutoEdit Members (on page 259)


• SYSRESOLVE Control Statement (on page 260)
 Local Variables (on page 260)
• Format (on page 260)
• General Information (on page 261)
 System Variables (on page 261)
• Format (on page 261)
• General Information (on page 261)
• Summary of System Variables (on page 262)

Control-M/Analyzer Variables
Control-M/Analyzer provides the capability to save and retain information in variables. Variables are used
to store system information, results of calculations, and information extracted from files. The maximum
length of Control-M/Analyzer variables (after resolving the %% operators described later in this chapter)
is 100 bytes, except for long string variables. (See SYSLSTR1,…SYSLSTR9 later in this chapter.)
Control-M/Analyzer variable names are not case sensitive.

Variable Types
Control-M/Analyzer uses the following types of variables:
 Database
 AutoEdit
 Local
 System
Each type differs from the others in the way it can be used and in the manner (and length of time) it is
stored, as described in Table 129.

223
Control-M/Analyzer User Guide

Table 129 Control-M/Analyzer Variable Types

Variable Type Description

Database "Permanent" variables stored in the Control-M/Analyzer Database


and accessible by Control-M/Analyzer rules. Output of data
balancing processes that have run in your environment can be
stored in Control-M/Analyzer Database variables.

AutoEdit Variables dynamically read from AutoEdit members during rule


execution. These variables can be accessed by any INCONTROL
product because they are stored in AutoEdit members.

Local Variables only accessible by the current Control-M/Analyzer rule.

System Variables, including environmental and runtime variables, that can


only be accessed during the current Control-M/Analyzer invocation.
The SYSDATE and SYSCENT variables provide support for calendar
operations.

%% Operator
The %% operator operates on Local, Database and System variables in the same manner as it operates
on AutoEdit variables. It provides AutoEdit capabilities to System variables and user-defined Local and
Database variables.
The %% variable format is:
%%var
In this format, var represents the name of the variable.
For more information about AutoEdit variable resolution, see AutoEdit Variables (on page 256).

Passing Variables to Blocks, Rules and User Routines


Local, Database and AutoEdit variables can be embedded in the ARG parameter of DO BLOCK, DO
CALLUSER, and DO RULE statements. For more information about these statements, see DO BLOCK:
Automated Balancing Statement (on page 368), DO CALLUSER: Automated Balancing Statement (on page
371), and DO RULE: Automated Balancing Statement (on page 416).

224
Control-M/Analyzer User Guide

Figure 107 Passing Variables to Blocks, Rules and User Routines

Note: Database variables can be embedded only if they have not yet been committed. After a Database
variable has been committed, it cannot be specified in the ARG parameter of DO BLOCK, DO CALLUSER,
or DO RULE.

Database Variables
When a rule processes data, the rule can save values in the Control-M/Analyzer Database for future use.
These values can be accessed by both the original rule that created the variable and other
Control-M/Analyzer rules. All Control-M/Analyzer rules can share information by accessing the Database.
Database variables must be created (defined) before they can be used. The definition consists of
parameters that contain basic information about the variable (such as its group and name). These
parameters also determine the number of values a variable can have. Each variable value represents a
generation: a historical occurrence of a variable and its value at that time.
Once a Database variable definition is created, rules can refer to and add generations to that variable.
Attributes can be specified to identify (to refer to) a specific variable generation from within a balancing
rule definition. The attributes are described briefly in Table 130.

225
Control-M/Analyzer User Guide

Table 130 Control-M/Analyzer Database Variables

Attribute Description

Database prefix Name prefix DB_, which identifies the variable as a Database
variable.

Group name Name of the group to which the Database variable belongs.

Variable name Name of the Database variable.

Generation Reference to the current or any previous value of the Database


variable.

Date Date of Database variable creation.

User key User-defined Database variable identifier.

Run ID User-defined run identifier. For example, Daily, Monthly) during


which the Database variable was created.

Example
Distinguish between accounting and marketing departments’ total expense figures by referring to the
group name when accessing the variables:
DB_ACCOUNTING.TOTALEXP and DB_MARKETING.TOTALEXP
For additional information about referring to Database variables, see "Variable Generation Attributes"
below.
 Note: If a rule definition refers to an undefined Database variable, Control-M/Analyzer can be
customized to: Automatically create the variable based on default settings, or
 Cause a runtime error and display a message in the sysout of the job.
For further information, see Automatic Database Variable Creation (on page 235).

Variable Generation Attributes


Control-M/Analyzer Database variables can serve as input for the evaluation process of a rule and can
store results of rule processing for later use by other rules and for statistical and historical purposes.
Within a rule, a Database variable is referred to by the DB_ prefix, its optional group name prefix, and its
variable name. Other attributes may be specified as suffixes to the variable name to precisely identify the
Database variable by generation, creation date, user key and run ID.
Note: If a variable name does not start with the prefix DB_ in a rule definition, the variable is assumed to
be a Local variable. The AutoEdit Operator %% can be specified as a prefix to a Database variable name.
For additional information, see %% Operator (on page 224).

226
Control-M/Analyzer User Guide

The variable name, prefixes, and suffixes form the Variable Reference Statement. The Variable Reference
Statement identifies the variable needed by a rule. A description of Database variable name components,
an explanation of how they are structured to produce Database Variable Reference Statements, and
examples of Database Variable Reference Statements are provided below.

Database Variable Name Components


Table 131 describes the Database variable name components.
Note: The @ symbol does not appear on all keyboards. If your keyboard does not have this symbol, use
the symbol whose hexadecimal representation is X`7C'.
Table 131 Database Variable Name Components

Command Description

AutoEdit prefix Prefix %% to the entire Database variable name (including prefix
DB_) only when specifying AutoEdit substitution. See "AutoEdit
Substitution of Database Variables" below.

Database prefix Prefix DB_ to the Database variable name. This is a reserved prefix.
It cannot be used for other types of Control-M/Analyzer variables.
Prefix DB_ is mandatory when referring to a Database variable from
within a rule definition. Prefix DB_ should not be specified when
defining the Database variable.

Group name prefix Name of the group to which the variable belongs. 1-20 characters.
Optional.
If not specified, the group of the variable is assumed to be the
group of the rule (meaning, the group under which the rule
executes). If specified, a period (.) is used as the separator between
the group name and variable name. However, if this Database
variable will be resolved by AutoEdit substitution (meaning, it has a
%% prefix) use a colon (:) as the separator between the group
name and variable name.
For more information, see the examples that follow this table.

Variable name Name of the variable, 1-20 characters. The first character must be
alphabetic. Mandatory.
Variable names must be unique within a group. However, the same
variable name may be specified in different groups.

227
Control-M/Analyzer User Guide

Command Description

Generation suffix Numeric reference to the current or any previous value of the
variable. Optional.
The prefix @G must precede the generation specification.
Generations are automatically numbered and renumbered from
newest to oldest in ascending order. The current value (and default)
is @G0, the preceding value is @G1, the value before the preceding
value is @G2, and so on.

Date suffix Date of Database variable creation. Optional. When specified, the
date must be in yymmdd format.
The prefix @D must precede the date specification.

User key suffix User-defined Database variable identifier. 1-20 alphanumeric


characters. User keys can only contain alphanumeric characters.
Optional.
The prefix @K must precede the user key specification.

Run ID suffix Site-defined run identifier. Run IDs can only contain alphanumeric
characters. Optional.
The prefix @R must precede the run ID specification.
The run identifier of all variables committed by a rule is determined
by the value of System variable SYSRUNID. This variable must be
set before the first DO COMMIT statement in the rule.

Note: When Database variables are accessed as input, each existing generation of a variable can be
accessed by specifying its generation number or another attribute of the variable generation. When
variables are accessed as output, only the user key attribute can be specified, indicating the user key of
the newly created generation.

228
Control-M/Analyzer User Guide

Examples of Database Variable Reference Statements


Table 132 Examples of Database Variable Reference Statements

Variable What the Variable Represents

DB_ACCOUNTING.TOTALEXP The total expenses of the accounting


department (current value).

DB_MARKETING.TOTALEXP The total expenses of the marketing


department (current value).

DB_TOTALEXP The total expenses of a department


(current value). The group is determined
by the group of the rule at execution time.

DB_MARKETING.TOTALEXP@G1 The previous total expenses figure of the


marketing department.

DB_MARKETING.TOTALEXP@D000101 Total expenses figure for the marketing


department for 01/01/00.

DB_TOTALEXP@RDAILY The total expenses figure of the current


group with a run identifier of DAILY.

%%DB_ACCOUNTING:TOTALEXP@G1 The previous total expenses figure of the


marketing department, which is resolved
using AutoEdit substitution. The period
separator is replaced by a colon separator.

AutoEdit Substitution of Database Variables


AutoEdit Substitution (by the %% operator) is especially useful for printing Database variables using
statement DO PRINT. When specifying AutoEdit substitution for Database variables, specify %% before
the entire name and, if it exists, replace the period separator (that separates the Group name prefix and
the variable name) with a colon separator.
For example, a Database variable with the Variable Reference Statement
DB_ACCOUNTING.TOTALEXP@G1
can be resolved using AutoEdit substitution by changing its Variable Reference Statement to
%%DB_ACCOUNTING:TOTALEXP@G1

229
Control-M/Analyzer User Guide

Example
Figure 108 AutoEdit Substitution of Database Variables
LIBRARY : CTB.PROD.RULES RULE : DBVARAE
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M43 GROUP PERSONNEL
UPDATED 04/04/00 - 10:20:09 BY M43
DESC
OPTIONS
===========================================================================
EXECUTE GETAVG UPON C
ON FILE FILENAME A00.EMPS
MODE DS LINECT 0000 DATASTAMP
WHEN LINE 001 - 999 COL 001 - 001 STOP AND/OR
STRING = .AL.
DO EXTRACT = DB_PERSONNEL.EMPNAME
LEVEL LINE +000 COL 0001 - 0020 PROCESS TYP
DO EXTRACT = DB_PERSONNEL.EMPSALARY
LEVEL LINE +000 COL 0021 - 0032 PROCESS TYP
DO PRINT = %%DB_PERSONNEL:EMPNAME %%DB_PERSONNEL:EMPSALARY F C
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE UPON C
PLEASE FILL IN RULE DEFINITION 11.42.28

For additional information on AutoEdit substitution, see Rules of AutoEdit Variable Substitution (on page
258).

Database Variable Reference Method


When a database variable value is created or read by a rule, Control-M/Analyzer scans the database for
the appropriate variable based on the Variable Reference Statement. Attribute search priorities exist for
determining which variable best matches the Variable Reference Statement. Attributes are listed in
Table 133 in the order in which Control-M/Analyzer uses them to search the Database:

230
Control-M/Analyzer User Guide

Table 133 Database Variable Search Attributes

Attributes Description

Group name If no group name is specified, the group of the current rule is
assumed. Control-M/Analyzer scans the Database for the specified
or assumed group name. If the searched for group name does not
exist, a runtime error occurs.

Variable name After the group is found, Control-M/Analyzer searches for variables
with the specified variable name.
A runtime error occurs when trying to read a Database variable that
does not exist in the Database for the specified or assumed group.
When setting (writing) a Database variable that does not exist in the
Database for the specified or assumed group:
The variable is created if automatic Database variable creation is
enabled.
A runtime error occurs if automatic Database variable creation is
disabled.
For more information, see Automatic Database Variable Creation (on
page 235).

Generation If no generation is specified, generation 0–the current value is


assumed. Control-M/Analyzer searches the Database for the
specified or assumed generation of the variable. If no such
generation exists, a runtime error occurs when trying to read a
Database variable.

Date If no generation is specified and a date suffix is specified,


Control-M/Analyzer searches for variables created on the specified
date. If no mach is found, a runtime error occurs. If several
matches are found, Control-M/Analyzer examines the other specified
attributes.

Note: User key and run ID are mutually exclusive and cannot be
specified in the same Variable Reference Statement.

User key If a User key is specified, Control-M/Analyzer searches for a variable


that matches all prior specifications and whose User key matches
the specified User key. If no match is found, a runtime error occurs.
If several matches are found, Control-M/Analyzer returns the value
of the oldest matching generation.

Run ID If a run ID is specified, Control-M/Analyzer searches for a variable


that matches all prior specifications with a run ID that matches the
specified run ID. If no match is found, a runtime error occurs.

231
Control-M/Analyzer User Guide

If several possibilities remain after all specified attributes have been examined, the oldest match is
accessed.
Examples
When matching the Variable Reference Statements listed below, refer to Table 134, which describes
Database variable attributes.
Table 134 Variable Database Attributes

Var# Group Variable Gen Date User Key Run ID

A MARKET GROSS_PROFIT 0 02/02/00 ADJUSTED DAILY

B MARKET GROSS_PROFIT 1 02/02/00 ACTUAL DAILY

C MARKET GROSS_PROFIT 2 02/02/00 FORECAST DAILY

D MARKET NET_PROFIT 0 02/02/00 ADJUSTED MONTHLY

E MARKET NET_PROFIT 1 02/02/00 FINAL MONTHLY

F MARKET NET_PROFIT 2 02/02/00 FINAL MONTHLY

G MARKET TAX_OWED 0 02/02/00 YEARLY

Table 135 Variable Reference Statements

Variable Reference Statement Var #

DB_MARKET.TAX_OWED G

DB_MARKET.GROSS_PROFIT@G1 B

DB_MARKET.GROSS_PROFIT@D980202 A

DB_MARKET.GROSS_PROFIT@D980303 Error

DB_MARKET.GROSS_PROFIT@D980101@KACTUAL B

DB_MARKET.GROSS_PROFIT@KACTUAL B

DB_MARKET.GROSS_PROFIT@KFINAL Error

DB_MARKET.NET_PROFIT@RMONTHLY@KADJUSTED Error. A user key and run ID cannot


be specified simultaneously.

DB_MARKET.@G0 Error

232
Control-M/Analyzer User Guide

Accessing Database Variables


General
During rule execution, Database variables are accessed, assigned values, and stored in the
Control-M/Analyzer Database using Variable Reference Statements. Each time a Database variable is
referenced, Control-M/Analyzer determines the value of the variable based on the value currently
specified in the Control-M/Analyzer Database.

Setting Database Variables


DO SET and DO EXTRACT statements enable the user to assign values to Database variables, as
described in Rule Definition (on page 348). When DO SET and DO EXTRACT statements are executed, the
value of the corresponding variable in the Database is accessed and automatically locked against (made
inaccessible to) other rules or online users that are processing concurrently.

Locking Database Variables


When other rules attempt to access (read or set) a variable that is locked, Control-M/Analyzer denies
access until the variable is unlocked by the rule that locked it.
A locked variable remains locked until the rule that locked the variable does one of the following:
 issues statement DO COMMIT=NOW (for more information, see DO COMMIT: Automated Balancing
Statement (on page 373))
 finishes processing the statement DO TERMINAT, which automatically commits all Database variables
that were set

Committing Database Variables


A DO COMMIT statement sets commitment options for writing the variable value back to the
Control-M/Analyzer Database and unlocks the variable – making it available to other rules. Various
methods are available for specifying the type of commit that should occur. For information about DO
COMMIT options and the DO SET statement, see Rule Definition (on page 348).
Examples
When defining rules, the user should take into account various variable locking and unlocking methods.
Examples of locking and committing strategies include:
 To lock a variable throughout the processing of the current rule until the new value is stored in the
Database: Initialize the variable to itself at the beginning of the rule and commit the variable at the
end of the rule.

233
Control-M/Analyzer User Guide

Table 136 Committing Database Variables – Example 1

Do Statements Database Variable Status

DO SET = DB_TOTAL=DB_TOTAL Locked

... Locked – while processing

DO COMMIT ALL Unlocked – new value written

Note: In the example above, if the DO COMMIT statement is omitted, the DB_TOTAL variable is
automatically committed and unlocked during rule termination.
 To exclusively perform calculations on a variable without storing the result in the Database: Use a DO
COMMIT statement with the DELETE option. No variables are committed (written) but the DO
COMMIT statement unlocks the variable.
Table 137 Committing Database Variables – Example 2

Do Statements Database Variable Status

DO SET = DB_TOTAL=DB_TOTAL Locked

... Locked – while processing

DO COMMIT DELETE Unlocked – new value is not written

 To access and process a variable without restricting its use by other rules, write the value of the new
variable to the Database after the new value has been calculated.
Table 138 Committing Database Variables – Example 3

Do Statements Database Variable Status

DO SET = TEMP=DB_TOTAL Unlocked

... Unlocked – while processing

DO SET = DB_TOTAL=TEMP Locked

DO COMMIT ALL Unlocked – new value is written

234
Control-M/Analyzer User Guide

 To create a new Database variable, no locking or committing is necessary.


Table 139 Committing Database Variables – Example 4

Do Statements Database Variable Status

DO SET = DB_TOTAL=DB_TOTAL Unlocked

... Unlocked – while processing

Automatic Database Variable Creation


Database variables are defined by the Online Database Variable Definition facility. After a Database
variable has been defined, the variable can be accessed by Control-M/Analyzer rules. Each time the value
of the variable changes, a new generation is automatically created.
However, if a rule attempts to access a Database variable that has not yet been defined (meaning, no
variable definition and no generations for this variable exist), one of the following occurs, depending on
the value of the SYSDBVARCREATE System variable:
 Y (Yes) – The variable is automatically created according to defaults specified by the SYSDBVARGENS
and SYSDBVARDESC System variables (see below).
 N (No) – The variable is not created and a runtime error occurs.
The initial value of the SYSDBVARCREATE System variable corresponds to the setting of the VARCRET
parameter in CTBPARM. If VARCRET is set to NO, SYSDBVARCREATE cannot be set to Y (Yes).
When Control-M/Analyzer automatically creates a Database variable, the variable is created according to
defaults set by the following Control-M/Analyzer System variables:
 SYSDBVARGENS – Default maximum value of generations for the Database variable. Initially, this
default value is set to the value of the VARGENS parameter in CTBPARM.
 SYSDBVARDESC – Default Database variable description. Initially, this default value is blank.
These defaults can be changed at any time by changing the SYSDBVARGENS and SYSDBVARDESC System
variables. DO SET statements are used to change the value of System variables.
The TYPE subparameter of the CREATED... BY... TYPE parameter can be viewed online in the Database
Variable Definition screen to see how the variable was created. The TYPE subparameter can have the
following values:
 B (Batch) – The Database variable was created automatically during rule execution.
 O (Online – The Database variable was created online by the user (using the Online Database
Definition facility).

235
Control-M/Analyzer User Guide

Database Variable Definition Screen


The various attributes of a Database variable accessed by a Control-M/Analyzer rule are called Database
variable parameters. This chapter provides detailed descriptions of all these parameters and their uses.
Database variable parameters only need to be defined once for each variable. Control-M/Analyzer uses
this framework for numerous values (generations) of the same variable.
Database variable parameters are defined by the Online Database facility using formatted screens.
Figure 109 Control-M/Analyzer Variable Definition Screen
-------------- Control-M/ANALYZER VARIABLE DEFINITION SCREEN --------------(BV.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
NAME TOTAL GROUP INVENTORY
CREATED 11/11/97 - 10:10:10 BY M18 TYPE O (B-BATCH,O-ONLINE)
DESC TOTAL ITEMS IN INVENTORY FOR ALL PARTS
===========================================================================
MAXIMUM ACTIVE GENERATIONS 0032 GEN TYPE I (I-INDEPENDENT,H-HIERARCHICAL)
CURRENT ACTIVE GENERATIONS 0032
OLDEST -31 DATE 11/11/97
LATEST 0 DATE 04/04/00
===========================================================================
TYPE VAR
MASK

============= >>>>>>>>> BOTTOM OF VARIABLE DEFINITION <<<<<<<<<<< =============

PLEASE FILL IN VARIABLE DEFINITION 10.10.10

Before proceeding with this chapter, all Control-M/Analyzer users should read the following:
 Database Variable Definition Facility (on page 86)
 Overview (on page 58), and the description of the Online facility that follows that page
All parameter definitions are stored in the Control-M/Analyzer Database. The Database consists of two
files – the Database Variable Basic file and the Database Variable Generation file. For additional
information, refer to the INCONTROL for z/OS Installation Guide.
Maintenance of the Database and management of Database variable definitions are performed using the
Online Definition facility and Database maintenance utilities. For more information, see the INCONTROL
for z/OS Administrator Guide, and the INCONTROL for z/OS Utilities Guide.

236
Control-M/Analyzer User Guide

Defining Database Variables


When creating Database variables, parameters must be defined. These parameters contain basic
information about the variable, such as group and name. They also determine the maximum number of
values (generations) a variable can have.
Database variable parameters are of the following types:
 Basic parameters specify basic information about the variable, such as group and description.
• NAME
• GROUPS
• CREATED...BY... TYPE
• DESC
 Generation parameters specify information about current and previous values of the variable.
• MAXIMUM ACTIVE GENERATIONS
• GEN TYPE CURRENT ACTIVE GENERATIONS
• OLDEST...DATE LATEST...DATE
 Validation parameters specify patterns to which variable values must conform (for example, length,
format, valid characters). For future use.
• TYPE MASK
Note: Avoid using Control-M/Analyzer reserved words when specifying Database variable names.
See B Reserved Words (on page 673), for a complete list of reserved words.

237
Control-M/Analyzer User Guide

Database Variable Parameters – Summary


Database variable parameters are listed in Table 140 and described in this chapter.
Table 140 Database Variable Parameters – Summary

Parameter Description

NAME Name of the Database variable.

GROUP Group of the Database variable.

CREATED...BY...TYPE Date of creation, User ID of the creator, and type of the


Database variable. The Database variable can be created either
online or batch (dynamically during job execution). For display
only.

DESC Description of variable (free text).

MAXIMUM ACTIVE Maximum number of generations of the Database variable that


GENERATIONS Control-M/Analyzer retains.

GEN TYPE For future use.

CURRENT ACTIVE Current number of generations of the Database variable. For


GENERATIONS display only.

OLDEST... DATE Generation and creation date of the oldest generation of the
Database variable. For display only.

LATEST... DATE Generation and creation date of the latest generation of the
Database variable. For display only.

TYPE For future use.

MASK For future use.

The following pages contain a detailed description of each of the Control-M/Analyzer Database variable
parameters. Parameters are arranged alphabetically.
Each parameter begins on a new page, including:
 A brief explanation of the purpose of the parameter.
 The format required for defining the parameter within an extract of the Database Variable Definition
screen.
 General Information explaining the parameter and its usage.
 Where applicable, some practical examples, illustrating implementation of the parameter.
For more information, see Database Variable Definition Facility (on page 86).

238
Control-M/Analyzer User Guide

NAME Basic Parameters


Assigns a name to the Database variable.
Figure 110 Name Parameter Format

NAME specifies a Database variable name of 1 through 20 characters. No blanks (except trailing blanks)
are permitted. The first letter must be alphabetic. Mandatory.

General Information
Variable names must be unique within a group.
When specifying the variable name in the Database Variable Definition screen, the DB_ prefix is assumed
and should not be specified.
When referring to a Database variable from within a rule definition, the DB_ prefix is not assumed and
must be specified.
The specified group name becomes an assumed prefix (attribute) of the variable name. When a rule
definition refers to a variable within the current group, the group name does not need to be specified.
When a rule definition refers to a variable from another group, the group name must be indicated
explicitly.

Example 1
Table 141 NAME Parameter Database Variables

Group Database Variable

QC (Quality Control) DB_QC.TOTAL1

OP (Operations) DB_OP.TOTAL1

If the current group is QC and the rule attempts to access TOTAL1 from within the QC group, the variable
can simply be referred to as DB_TOTAL1 within the rule definition.
If the current group is QC and the rule attempts to access TOTAL1 from within the OP group, the variable
must be referred to as DB_OP.TOTAL1 within the rule definition.

239
Control-M/Analyzer User Guide

For details about referring to Database variables within rule definitions, see Database Variable Reference
Method (on page 230).

Example 2
Figure 111 Name Parameter – Example 2
------------------- CONTROL-M/ANALYZER VARIABLE DEFINITION ---------------(BV.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
NAME TOTAL GROUP INVENTORY
CREATED 11/11/97 - 10:10:10 BY M18 TYPE O (B-BATCH,O-ONLINE)
DESC TOTAL ITEMS IN INVENTORY FOR ALL PARTS
===========================================================================
MAXIMUM ACTIVE GENERATIONS 0032 GEN TYPE I (I-INDEPENDENT,H-HIERARCHICAL)
CURRENT ACTIVE GENERATIONS 0032
OLDEST -31 DATE 11/11/97
LATEST 0 DATE 04/04/00
===========================================================================
TYPE VAR
MASK

============= >>>>>>>>> BOTTOM OF VARIABLE DEFINITION <<<<<<<<<<< =============

PLEASE FILL IN VARIABLE DEFINITION 10.10.10

240
Control-M/Analyzer User Guide

GROUP Basic Parameters


Specifies the name of the group.
Figure 112 GROUP Parameter Format

GROUP specifies a group name of 1 through 20 characters. No blanks (except trailing blanks) are allowed.
GROUP is automatically set to the group name specified when entering the Database Variable Definition
screen. Mandatory.

General Information
This parameter associates the Database variable with a certain group. The specified group becomes an
assumed prefix to (and attribute of) the Database variable name.
GROUP appears in all important messages relating to the Database variables of the group.
Jobs, missions, and variables may be grouped to create a separate environment for different applications.
A detailed explanation of the GROUP concept is provided in Group Concept and Group Modes (on page
33).

241
Control-M/Analyzer User Guide

Example
Figure 113 Group Parameter Example
------------------ CONTROL-M/ANALYZER VARIABLE DEFINITION ----------------(BV.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
NAME TOTAL GROUP INVENTORY
CREATED 11/11/97 - 10:10:10 BY M18 TYPE O (B-BATCH,O-ONLINE)
DESC TOTAL ITEMS IN INVENTORY FOR ALL PARTS
===========================================================================
MAXIMUM ACTIVE GENERATIONS 0032 GEN TYPE I (I-INDEPENDENT,H-HIERARCHICAL)
CURRENT ACTIVE GENERATIONS 0032
OLDEST -31 DATE 11/11/97
LATEST 0 DATE 04/04/00
===========================================================================
TYPE VAR
MASK

============= >>>>>>>>> BOTTOM OF VARIABLE DEFINITION <<<<<<<<<<< =============

PLEASE FILL IN VARIABLE DEFINITION 10.10.10

242
Control-M/Analyzer User Guide

CREATED...BY...TYPE: Basic Parameters


Displays the date and time the Database variable was initially created, the creator of the variable and the
type of variable.
Figure 114 CREATED...BY...TYPE: Parameter Format

The date and time created and the BY and TYPE subparameters are set by Control-M/Analyzer and cannot
be changed. For display only.
The BY subparameter indicates the user ID of the online or batch user who created the Database
variable.
The TYPE subparameter can have the values shown in Table 142.
Table 142 Values of the TYPE subparameter

Value Description

B (Batch) The Database variable was created automatically during rule


execution by the Automatic Database Variable Creation facility. This
facility is described later in this chapter.

O (Online) The Database variable was created online by a user.

General Information
The date, time, and creator are established when the Database variable is initially created.
The TYPE subparameter is set according to the environment in which the Database variable was created.
If the variable was created by the Online facility, TYPE is set to O. If the variable was automatically
created by a rule, TYPE is set to B.

243
Control-M/Analyzer User Guide

Example
Figure 115 CREATED...BY...TYPE...Parameter Example
----------------- CONTROL-M/ANALYZER VARIABLE DEFINITION -----------------(BV.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
NAME TOTAL GROUP INVENTORY
CREATED 11/11/97 - 10:10:10 BY M18 TYPE O (B-BATCH,O-ONLINE)
DESC TOTAL ITEMS IN INVENTORY FOR ALL PARTS
===========================================================================
MAXIMUM ACTIVE GENERATIONS 0032 GEN TYPE I (I-INDEPENDENT,H-HIERARCHICAL)
CURRENT ACTIVE GENERATIONS 0032
OLDEST -31 DATE 11/11/97
LATEST 0 DATE 04/04/00
===========================================================================
TYPE VAR
MASK

============= >>>>>>>>> BOTTOM OF VARIABLE DEFINITION <<<<<<<<<<< =============

PLEASE FILL IN VARIABLE DEFINITION 10.10.10

244
Control-M/Analyzer User Guide

DESC: Basic Parameters


Describes the Database variable in free text.
Figure 116 DESC: Parameter Format

DESC specifies a description from 1 through 50 characters.

General Information
A Database variable description can be specified in any language. The description is used as an internal
help facility to assist the user in identifying the variable.

Example
Figure 117 DESC Parameter Example
-------------------- CONTROL-M/ANALYZER VARIABLE DEFINITION --------------(BV.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
NAME TOTAL GROUP INVENTORY
CREATED 11/11/97 - 10:10:10 BY M18 TYPE O (B-BATCH,O-ONLINE)
DESC TOTAL ITEMS IN INVENTORY FOR ALL PARTS
===========================================================================
MAXIMUM ACTIVE GENERATIONS 0032 GEN TYPE I (I-INDEPENDENT,H-HIERARCHICAL)
CURRENT ACTIVE GENERATIONS 0032
OLDEST -31 DATE 11/11/97
LATEST 0 DATE 04/04/00
===========================================================================
TYPE VAR
MASK

============= >>>>>>>>> BOTTOM OF VARIABLE DEFINITION <<<<<<<<<<< =============

PLEASE FILL IN VARIABLE DEFINITION 10.10.10

245
Control-M/Analyzer User Guide

MAXIMUM ACTIVE GENERATIONS: Generation Parameters


Limits the number of generations (values) of the Database variable that Control-M/Analyzer stores.
Figure 118 MAXIMUM ACTIVE GENERATIONS: Parameter Format

Mandatory. The maximum number of Database variable generations Control-M/Analyzer can track is 1000.
The minimum value for this parameter is 1.
This parameter should be specified the first time the Database variable is created (with option I) by the
Online facility.

General Information
The MAXIMUM ACTIVE GENERATIONS parameter can be changed at any time on the Database Variable
Definition screen. It can also be changed by the CTBDBVCG utility. For more information about the
CTBDBVCG utility, see the INCONTROL for z/OS Utilities Guide.
The current (latest) generation of a variable is always generation 0. The previous historical occurrence
(value) of a variable is generation –1, and so on.
Therefore, if 50 generations of a variable have been stored, the earliest generation is generation –49.
Because the maximum number of generations that Control-M/Analyzer can track is 1000, the largest
generation number possible
is –999.
MAXIMUM ACTIVE GENERATIONS is used by Control-M/Analyzer to determine when to delete earlier
variable generations to make room for newer ones.
For example, assume that the MAXIMUM ACTIVE GENERATIONS parameter is set to 10 and there are
currently 10 active generations (designated 0 through –9). If a rule adds a new value to the variable, the
oldest generation, –9, is deleted. The new value becomes generation 0, the previous current value
becomes generation –1, and so on.
However, if the MAXIMUM ACTIVE GENERATIONS parameter is set to 10 and there are currently 5 active
generations (designated 0 through –4), no values are deleted if a rule adds a new value to the variable.
When a new value becomes generation 0, the previous current value becomes generation –1, and so on,
resulting in 6 active generations (designated 0 through –5).
Deleted Database variables are assigned a generation value of ***.

246
Control-M/Analyzer User Guide

Example
Figure 119 MAXIMUM ACTIVE GENERATIONS Parameter Example
------------------- CONTROL-M/ANALYZER VARIABLE DEFINITION ---------------(BV.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
NAME TOTAL GROUP INVENTORY
CREATED 11/11/97 - 10:10:10 BY M18 TYPE O (B-BATCH,O-ONLINE)
DESC TOTAL ITEMS IN INVENTORY FOR ALL PARTS
===========================================================================
MAXIMUM ACTIVE GENERATIONS 0032 GEN TYPE I (I-INDEPENDENT,H-HIERARCHICAL)
CURRENT ACTIVE GENERATIONS 0032
OLDEST -31 DATE 11/11/97
LATEST 0 DATE 04/04/09
===========================================================================
TYPE VAR
MASK

============= >>>>>>>>> BOTTOM OF VARIABLE DEFINITION <<<<<<<<<<< =============

PLEASE FILL IN VARIABLE DEFINITION 10.10.10

247
Control-M/Analyzer User Guide

GEN TYPE: Generation Parameters


For future use.
Figure 120 GEN TYPE: Parameter Format

248
Control-M/Analyzer User Guide

CURRENT ACTIVE GENERATIONS: Generations Parameter


Displays the number of generations of the Database variable that are currently active. CURRENT ACTIVE
GENERATIONS.
Figure 121 CURRENT ACTIVE GENERATIONS Parameter Format

For display only. The displayed number never exceeds the value of the MAXIMUM ACTIVE GENERATIONS
parameter.

General Information
This informative field is automatically updated by Control-M/Analyzer throughout the existence of a
variable and cannot be changed by the user.
If CURRENT ACTIVE GENERATIONS would exceed the number specified in the MAXIMUM ACTIVE
GENERATIONS parameter, Control-M/Analyzer removes the oldest active generation. See the MAXIMUM
ACTIVE GENERATIONS parameter for a description of how Control-M/Analyzer removes the oldest
generation.

249
Control-M/Analyzer User Guide

Example
Figure 122 CURRENT ACTIVE GENERATIONS Parameter Example
---------------- CONTROL-M/ANALYZER VARIABLE DEFINITION -----------------(BV.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
NAME TOTAL GROUP INVENTORY
CREATED 11/11/97 - 10:10:10 BY M18 TYPE B (B-BATCH,O-ONLINE)
DESC TOTAL ITEMS IN INVENTORY FOR ALL PARTS
============================================================================
MAXIMUM ACTIVE GENERATIONS 0032 GEN TYPE I (I-INDEPENDENT,H-HIERARCHICAL)
CURRENT ACTIVE GENERATIONS 0032
OLDEST -31 DATE 11/11/97
LATEST 0 DATE 04/04/00
============================================================================
TYPE VAR
MASK

============= >>>>>>>>> BOTTOM OF VARIABLE DEFINITION <<<<<<<<<<< =============

PLEASE FILL IN VARIABLE DEFINITION 10.10.10

250
Control-M/Analyzer User Guide

OLDEST... DATE: Generation Parameters


Displays the generation number and creation date of the oldest generation of a Database variable can be
modified to call user-defined processes. See the IOA.SAMPEXIT library for information about User Exit
CTBX010. For information about compiling and linking the CTBX010 member, see the INCONTROL for
z/OS Installation Guide.
Figure 123 OLDEST... DATE Parameters Format

For display only.

General Information
The generation number and creation date of the oldest existing generation for the current Database
variable is displayed.

Example
Figure 124 OLDEST...DATE Parameter Example
---------------- CONTROL-M/ANALYZER VARIABLE DEFINITION -----------------(BV.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
NAME TOTAL GROUP INVENTORY
CREATED 11/11/97 - 10:10:10 BY M18 TYPE O (B-BATCH,O-ONLINE)
DESC TOTAL ITEMS IN INVENTORY FOR ALL PARTS
===========================================================================
MAXIMUM ACTIVE GENERATIONS 0032 GEN TYPE I (I-INDEPENDENT,H-HIERARCHICAL)
CURRENT ACTIVE GENERATIONS 0032
OLDEST -31 DATE 11/11/97
LATEST 0 DATE 04/04/00
===========================================================================
TYPE VAR
MASK

============= >>>>>>>>> BOTTOM OF VARIABLE DEFINITION <<<<<<<<<<< =============

251
Control-M/Analyzer User Guide

PLEASE FILL IN VARIABLE DEFINITION 10.10.10

252
Control-M/Analyzer User Guide

LATEST... DATE: Generation Parameters


Displays the generation number and creation date of the latest generation of a Database variable.
Figure 125 LATEST... DATE Parameters Format

For display only.

General Information
The generation number and creation date of the latest generation of the Database variable is displayed.
Unless "deleted," the latest generation of a Database variable is represented by the number 0. If the
latest generation has been "deleted," it is represented by ***.

253
Control-M/Analyzer User Guide

Example
Figure 126 LATEST...DATE Parameter Format
------------------- CONTROL-M/ANALYZER VARIABLE DEFINITION ---------------(BV.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
NAME TOTAL GROUP INVENTORY
CREATED 11/11/97 - 10:10:10 BY M18 TYPE O (B-BATCH,O-ONLINE)
DESC TOTAL ITEMS IN INVENTORY FOR ALL PARTS
===========================================================================
MAXIMUM ACTIVE GENERATIONS 0032 GEN TYPE I (I-INDEPENDENT,H-HIERARCHICAL)
CURRENT ACTIVE GENERATIONS 0032
OLDEST -31 DATE 11/11/97
LATEST 0 DATE 04/04/00
===========================================================================
TYPE VAR
MASK

============= >>>>>>>>> BOTTOM OF VARIABLE DEFINITION <<<<<<<<<<< =============

PLEASE FILL IN VARIABLE DEFINITION 10.10.10

TYPE: Validation Parameter


For future use.
Figure 127 TYPE Parameter Format

254
Control-M/Analyzer User Guide

MASK: Validation Parameters


For future use.
Figure 128 MASK Parameter Format

255
Control-M/Analyzer User Guide

AutoEdit Variables
AutoEdit variables are generic variables with values that are determined (resolved) at the time a rule
containing an AutoEdit variable is invoked.
Using the AutoEdit facility enhances the variety of balancing actions Control-M/Analyzer can perform.

How AutoEdit Variables Are Used


When Control-M/Analyzer performs commands (such as DO, IF), the contents of certain parameters are
scanned for special symbols (starting with %%). These parameters are analyzed and the contents are
automatically replaced by the resolved values. The modified command is then activated. To determine
which commands and fields accept AutoEdit variables, see the parameter descriptions in this chapter.
Rules that use the AutoEdit facility are clear and simple, yet they enable any kind of action to be taken.
For example:
 A DO COND statement can contain the current date as a parameter.
 The job ID of the job that is being balanced can be included in a command issued by a DO SHOUT
statement.
You can use a DO SET statement to define your own AutoEdit variables and assign values to them. These
values can be used in subsequent DO statements of the rule.
Using DO GETMEM, DO ADDSYM, and DO PUTMEM statements, AutoEdit variables are read from and
written to PDS library members. Therefore, AutoEdit variables can be used:
 in subsequent executions of the same rule
 in other rules
 by any INCONTROL product that uses the AutoEdit facility
A DO GETMEM statement reads an AutoEdit member into memory, making its AutoEdit variables available
to the rule.
A DO ADDSYM statement adds new AutoEdit variables to a new or existing AutoEdit member.
A DO PUTMEM statement writes to disk all changes made to an AutoEdit member.
To add a new AutoEdit variable to a member, use a DO GETMEM statement (to read the member into
memory), a DO ADDSYM statement (to add the variable), and a DO PUTMEM statement (to write the
changes to disk).
To modify an existing AutoEdit variable, use a DO GETMEM statement (to read the AutoEdit variables of
the member into memory), a DO SET statement (to change the value of the variable), and a DO PUTMEM
statement (to write the changes to disk).
Note: If a rule refers to an AutoEdit variable through a DO ADDSYM statement , the variable is created
even if the associated MEM member was not read (by a DO GETMEM statement). Consider the following
when using a DO PUTMEM statement:

256
Control-M/Analyzer User Guide

 If the MEM AutoEdit member does not currently exist in the LIBSYM library, the member is added to
the library.
 If the MEM AutoEdit member does exist in the LIBSYM library, the member is not replaced with the
new values and a runtime error occurs.
 The characters @ and # are not valid in Control-M/Analyzer AutoEdit variable names.
For an example of how the %%LOCAL_CURRENCY and %%ROUND_CURRENCY AutoEdit variables can be
used for currency conversions, see D Euro Support (on page 678).
The Rule Definition screen illustrated in Figure 129 displays examples of AutoEdit Variables.
Figure 129 Examples of the Auto Edit Variables
LIBRARY : CTB.PROD.RULES RULE :BANKDAYS
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE INIT UPON C
ON DATA
ALWAYS
DO GETMEM = LSTBNKDY
LIBSYM CTB.PROD.SYMBOLS
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE GETDATES UPON C
ON SYSOUT PROCST PGMST STEP01 DDNAME BANKDAYS JOBNM
MODE PG LINECT 0000 DATASTAMP
WHEN LINE 001 - 060 COL 001 - 132 STOP AND/OR
STRING = |
EXTRACT = MONTH
LEVEL LINE +000 COL +002 - +005 PROCESS TYP
ADDSYM = %%LAST_BANKING_DAY_%%MONTH MEM LSTBNKDY
LIBSYM CTB.PROD.SYMBOLS
DO EXTRACT = %%LAST_BANKING_DAY_%%MONTH
LEVEL 0 LINE +000 COL +002 - +007 PROCESS TYP
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE FINISH UPON C
ON DATA
ALWAYS
DO PPUTMEM = LSTBNKDY
LIBSYM CTB.PROD.SYMBOLS
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 17.07.34

Each rule can reference (read) more than one AutoEdit member. Other AutoEdit members can be
accessed with a DO GETMEM statement. AutoEdit members can be written to disk using a DO PUTMEM
statement. For additional information see DO ADDSYM: Automated Balancing Statement (on page 364),
DO GETMEM: Automated Balancing Statement (on page 397), and DO PUTMEM: Automated Balancing
Statement (on page 412).
Note: No rollback mechanism is available for AutoEdit members. It is your responsibility to handle
changes to AutoEdit members.

257
Control-M/Analyzer User Guide

Searching for AutoEdit Variables


As each AutoEdit member is read by statement DO GETMEM, AutoEdit variables in that member are
recorded in a list in the order they occur in the member. When resolving an AutoEdit variable, this list is
searched from top to bottom. If the same variable name occurs in the list more than once (for
example, because it occurs in more than one member), the first occurrence is used and other occurrences
are ignored.

Format
AutoEdit processing can be performed on all types of Control-M/Analyzer variables: Local, Database,
System and AutoEdit.
Variables to be resolved are recognized by their %% prefix. These variables are referenced in the usual
IOA AutoEdit manner. The names of these variables are not case-sensitive.
AutoEdit processing can be performed on Control-M/Analyzer Local, Database and System variables by
prefixing %% to the variable name. If both a Local variable and an AutoEdit variable (read from an
AutoEdit member by a DO GETMEM statement) exist with the same variable name, the value of the Local
variable is resolved.
The AutoEdit variable format is %%var, %%DB_var or %%SYS_var, where var represents the name of
the variable.
For information about processing (resolving) %% operators, see Rules of AutoEdit Variable Substitution
(on page 258).

Rules of AutoEdit Variable Substitution


An AutoEdit symbol can be any alphanumeric string starting with %%. The characters $ and _ are also
valid. Lowercase characters are not translated to uppercase characters upon resolution. However,
Control-M/Analyzer variable names are not case sensitive.
Variables are evaluated sequentially from right to left, until the symbol is assigned a value. For example
%%SMF_TAPE_%%SYSDAY,
resolves on the third of the month to
%%SMF_TAPE_03,
Control-M/Analyzer then tries to resolve the symbol %%SMF_TAPE_03,
Assuming the value of the symbol in the global environment is EE1022, the result is
EE1022
 To concatenate two symbols, separate them with a period. For example
%%SYSDAY.%%SYSMONTH
resolves on the 3rd of December to
0312
Note: The combination %%SYSDAY%%SYSMONTH means that, during December, the
%%SYSDAY12 user-defined variable must be resolved.

258
Control-M/Analyzer User Guide

 To put a period between two AutoEdit symbols, use two consecutive periods. For example
%%SYSDAY..%%SYSMONTH
resolves on the 3rd of December to
03.12
 To concatenate a symbol and a constant, use %%. (concatenation symbol). For example
A91%%SYSDAY%%.UP
resolves on the 3rd of December to
A9103UP
Note: The combination A91%%SYSDAYUP involves a search for the symbol %%SYSDAYUP.

Assigning AutoEdit Variables With DO SET


DO SET statements are used to assign values to Local variables, Database variables, and AutoEdit
variables. When assigning values to AutoEdit variables, DO SET statements can have the following
formats:
DO SET = %%symbol=value
DO SET = %%symbol=valid expression
DO SET = %%symbol=control statements

The symbol must be a valid user-defined AutoEdit symbol.


Note: The maximum number that can be handled by mathematical AutoEdit operations is 231-1
(2147483647).
Control-M/Analyzer attempts to resolve the symbol to a single value by processing it from right to left. For
example
DO SET = %%BACKUP_UNIT_%%SYSWDAY=EE%%SYSMONTH.%%SYSDAY

On Sunday, the 24th of December, the user-defined symbol %%BACKUP_UNIT_1 is assigned the value
EE1224.
If the symbol assigned in a DO SET statement is not completely resolved, the default action is to cancel
the DO SET action and all subsequent actions of the current rule activation. This default can be
overridden by specifying SYSRESOLVE=NO in a previous DO SET statement, in which case the symbol is
resolved as completely as possible before performing the DO statement in which it is found. The
SYSRESOLVE statement format is described in SYSRESOLVE Control Statement (on page 260).
Note: SYSRESOLVE=NO is not currently available.

Adding AutoEdit Variables to AutoEdit Members


A DO ADDSYM statement adds a newly created AutoEdit variable to an AutoEdit member previously read
by the DO GETMEM statement.
The following statement

259
Control-M/Analyzer User Guide

DO ADDSYM = %%symbol MEM <member> LIB <library>

adds the symbol to the specified AutoEdit member. The symbol can subsequently be given a value. The
newly created AutoEdit variable is saved in the PDS library when the entire AutoEdit member is saved by
the DO PUTMEM statement.

SYSRESOLVE Control Statement


Control-M/Analyzer always attempts to resolve a symbol that begins with %%. If the symbol cannot be
fully resolved, the default action is to cancel the action containing the symbol and any subsequent actions
of the current activation of the rule. This default can be overridden by using the SYSRESOLVE=NO
control statement in a previous DO SET statement.
Note: SYSRESOLVE=NO is not currently available.
Valid formats for SYSRESOLVE statements are:
SYSRESOLVE=YES
SYSRESOLVE

If one or more symbols cannot be resolved, the rule actions are canceled.
SYSRESOLVE=NO

Symbols that cannot be fully resolved are resolved as completely as possible before performing the
current DO statement.
A SYSRESOLVE statement is assigned in a DO SET statement and affects all subsequent statements until
the next SYSRESOLVE statement in the rule.
Example
DO SET = SYSRESOLVE=NO
DO SHOUT TO TSO-PROD URGENCY R
= PLEASE SET THE VALUE OF THE %%INDEX_DOLLAR

In this example, the message "shouted" to user TSO-PROD contains the string %%INDEX_DOLLAR
literally – %%INDEX_DOLLAR is not resolved.

Local Variables
Control-M/Analyzer Local variables are used to temporarily store values that are needed only by the
current rule. The current rule has complete access to the variable, but upon rule termination the variable
value is no longer kept. Rules that are called by the current rule (by statement DO RULE) do not have
access to the Local variables of the calling rule unless these variables are passed as arguments.

Format
The maximum length of local variable names is 20 characters. The first character must be alphabetic
(A-Z). The remaining characters may be alphabetic, numeric, or the symbols @, _, #, and $. Local
variable names are not case sensitive. Local variable names cannot start with Database prefix DB_ or
System variable prefix SYS.

260
Control-M/Analyzer User Guide

General Information
Local variables may be accessed through:
 Direct reference in a Control-M/Analyzer expression.
DO SET = COUNTER=100
 Reference using the %% operator.
DO SHOUT TO TSO-M18 URGENCY R
= LOOP OCCURRED %%COUNTER TIMES

Local variables are created during rule execution at the first reference to the variable name. DO SET and
DO EXTRACT statements are used to give values to Local variables. For more information on DO SET and
DO EXTRACT statements, see Rule Definition (on page 348).

System Variables
System variables are predefined, commonly used variables with values that are automatically updated and
maintained by Control-M/Analyzer. They are global in nature and can be accessed by any
Control-M/Analyzer rule at any time.

Format
The System variables are listed below. System variables have reserved names that are not case sensitive.

General Information
There are two categories of System variables:
 Read-only variables that cannot be changed by the user.
These variables, such as SYSVER (Control-M/Analyzer version), SYSDATE (system date) and SYSTIME
(system time), are determined by the system.
 Variables that can be changed by the user.
These variables can be set using DO EXTRACT and DO SET statements. These variables include
BARGnn (for passing arguments to a block), RARGnn (for passing arguments to a rule), and
SYSCPROCn (for defining sequences of built-in or user-defined processes). For more information, see
DO EXTRACT: Automated Balancing Statement (on page 382) and DO SET: Automated Balancing
Statement (on page 418). For more information about SYSCPROCn, see Summary of System Variables
(on page 262).
System variables can be accessed by:
 A direct reference in a Control-M/Analyzer expression:
IF 'SYSRULE=REORDER'
 A %% operator variable reference:
DO PRINT 'RULE TERMINATED OK ON %%SYSDATE'

261
Control-M/Analyzer User Guide

For information about processing the %% operator, see Rules of AutoEdit Variable Substitution (on page
258).

Summary of System Variables


The Control-M/Analyzer System variables are listed below in alphabetical order. Values of System
variables marked with an asterisk (*) can be modified by the user using a DO SET statement.
Table 143 Summary of System Variables

Variable Description

BARGnn* Block arguments for passing parameters to a block.

RARGnn* Rule arguments for passing parameters to a rule.

SYSBARGNO Specifies the number of block arguments.

SYSCATEG Current category name.

SYSCENT First two digits in the current year (for example, 19 in the year
1998).
SYSCENT returns 20 on 1 January 2000.

SYSCURLINE Holds the current line to be compared by an ON COMPARE


statement. This system variable is not limited in length, as
opposed to regular variables, which are limited to 100 bytes.
This variable is used only by an ON COMPARE statement
(including its optional user blocks).

SYSSRCHALL* Indicates whether to search each qualifying line for all


occurrences or only the first occurrence of the string specified in
a WHEN statement. If SYSSRCHALL=1, the line is searched until
all occurrences are found. IF SYSSRCHALL=0 (the default value),
searching in each line stops when the first occurrence of the
string in that line is found.
For example:
DO SET ‘SYSSRCHALL’ EVAL ‘0’ (default value)
DO SET ‘SYSSRCHALL’ EVAL ‘1’

262
Control-M/Analyzer User Guide

Variable Description

SYSCPROCn Nine user-defined System variables (n is a number from 1


through 9) that provide a mechanism for combining sequences
of processes into a single BCPROCn combined process that can
afterwards be used as a PROCESS in a DO EXTRACT statement.
Any meaningful sequence of built-in or user-defined processes
can be made into a combined process using a DO SET
statement.
For example:
DO SET SYSCPROC1='BW1 BTUPPER BX12345 BX67890'

Each process in the list must be separated by a blank.


When a BCPROCn combined process is used in a DO EXTRACT
statement, the processes it represents are implemented in the
same order (left to right) they had in the DO SET statement.
Each SYSCPROCn variable must be defined by a DO SET
statement before it is used by the DO EXTRACT statement. The
SYSCPROCn definition remains effective until the rule terminates
unless redefined by a subsequent DO SET statement in the rule.
For more information about DO EXTRACT and DO SET
statements, see DO EXTRACT: Automated Balancing Statement
(on page 382) and DO SET: Automated Balancing Statement (on
page 418).

SYSDATE System date.


SYSDATE returns 000101 on 1 January 2000.

SYSDAY Day portion of system date (format dd).

SYSDBVARCREATE* Flag that indicates whether Control-M/Analyzer should


automatically create a Database variable (according to defaults)
if a rule refers to a variable (with a DB_ prefix) that has not
been defined. For more information, seeAutomatic Database
Variable Creation (on page 235).
Valid values are:
 Y (Yes) – Control-M/Analyzer should create the Database
variable.
 N (No) – Control-M/Analyzer should not create the Database
variable.
Note: The Database variable is only created automatically if
both the SYSDBVARCREATE system variable and the VARCRET
parameter in the CTBPARM member are set to Y.

263
Control-M/Analyzer User Guide

Variable Description

SYSDBVARGENS* Default maximum value of Database variable generations for


Database variables created automatically by Control-M/Analyzer.
For more information, see the SYSDBVARCREATE System
variable above.
The initial value of this default is the value specified by the
VARGENS parameter in the CTBPARM member.

SYSDBVARDESC* Default description for Database variables created automatically


by Control-M/Analyzer. See System variable SYSDBVARCREATE
above. The initial value of this description is blank.

SYSDECCHAR* Specifies the decimal point character indicator. For information


about how the value of SYSDECCHAR affects output formatting,
see Dynamic Print Formatting Facility (on page 407).
If the value of SYSDECCHAR is DOT, the decimal point indicator
is a period and the thousands separator is a comma.
If the value of SYSDECCHAR is COMMA, the decimal point
indicator is a comma and the thousands separator is a period.
The default value of SYSDECCHAR is the value of the DEECHAR
installation parameter in the CTBPARM member of the
Control-M/Analyzer Parameters library.

SYSEXTBLANK* Alternative value for blank values extracted during rule


execution. If SYSEXTBLANK is initialized, blank values
subsequently extracted by the DO EXTRACT statement are set to
the value of SYSEXTBLANK. Otherwise, the extracted values
remain blank.
SYSEXTBLANK is initialized by the DO SET statement. For
additional information on how the DO EXTRACT statement
operates, see DO EXTRACT Processes (on page 389).
Example
DO SET = SYSEXTBLANK='0' C
DO EXTRACT = TOTAL1
LEVEL 0 LINE +000 COL 0051 - 0054 PROCESS TYP
DO

Since SYSEXTBLANK was previously set to 0, if the value


extracted is blank, TOTAL1 is set to 0 (meaning, the value
specified for SYSEXTBLANK).

264
Control-M/Analyzer User Guide

Variable Description

SYSEXTUPROC* Expression that contains a reference to the SYSEXTVAL System


variable (the value extracted by the DO EXTRACT statement).
This expression specifies a user-defined process that is applied
when a DO EXTRACT statement is run with the BUPROC process
(described in DO EXTRACT: Automated Balancing Statement (on
page 382)).
For example, our original data contains information in inches,
but we need information in centimeters to process the data. We
could extract the information (in inches) and convert it each time
to centimeters with an appropriate DO SET statement. Instead,
we can specify the desired process one time by setting the
SYSEXTUPROC System variable and then executing the DO
EXTRACT statement as shown in the following example.
Example
DO SET = SYSEXTUPROC='SYSEXTVAL * 2.54' C
DO EXTRACT = CENTIM
LEVEL 0 LINE +000 COL 0051 - 0054 PROCESS BUPROC TYP
DO

The value in inches extracted from the specified line and


columns is evaluated according to the expression in
SYSEXTUPROC and its value is stored in the CENTIM variable.

SYSEXTVAL The value extracted by process BUPROC of the DO EXTRACT


statement. (For additional information see DO EXTRACT:
Automated Balancing Statement (on page 382).) The extracted
value is saved in this System variable. The SYSEXTUPROC
System variable (described above) must be set to an expression
that contains a reference to the SYSEXTVAL System variable.

SYSGROUP Current group name.

SYSJOBID Job ID of the current job.

SYSJOBNAME Current job name.

265
Control-M/Analyzer User Guide

Variable Description

SYSLSTR1,... These are long string variables that are not limited in length
SYSLSTR9* (unlike regular variables that are limited to 100 bytes). These
long string variables can be used by the following
Control-M/Analyzer statements, functions and operators:
 IF expressions
 DO PRINT
 DO SET
 SUBSTR
 MSUBSTMASK
 // (String concatenation)

SYSMISSION Current mission name.

SYSMONTH Month portion of system date (format mm).

SYSNDATE Next scheduling date. Varies, depending on the method by


which Control-M/Analyzer is invoked, as follows:
 If by Control-M/Analyzer rule, the next day
(meaning, tomorrow).
 If by Control-M/Analyzer mission, next scheduling date of
the Control-M/Analyzer mission.
 If by Control-M, next scheduling date of the Control-M
production job.
 If by Control-D or Control-V, next scheduling date of the
Control-D or Control-V decollating mission.

SYSNULL Null variable (created by setting the variable length of zero).


SYSNULL is used in a DO SET statement to set a variable to
"null."
For example:
DO SET = MYVAR=SYSNULL

266
Control-M/Analyzer User Guide

Variable Description

SYSOPT Control-M/Analyzer invocation method. Valid values are:


 CTBJOB—By a job step
 CTBUSER—By a user program
 CTMWORK—By Control-M
 CTDFIRST—By Control-D, first invocation (meaning, before
the first CDAM page is received)
 CTDWORK—By Control-D (meaning, for each CDAM page
received)
 CTDLAST—By Control-D, last invocation (meaning, after all
CDAM pages are received)
For additional information about invoking Control-M/Analyzer,
see Introduction (on page 19) and Control-M/Analyzer Variables
(on page 222).

SYSODATE Original scheduling date. Varies, depending on the method by


which Control-M/Analyzer is invoked, as follows:
 If by Control-M/Analyzer rule, the current day
(meaning, today).
 If by Control-M/Analyzer mission, original scheduling date of
the Control-M/Analyzer mission.
 If by Control-M, original scheduling date of the Control-M
production job.
 If by Control-D or Control-V, original scheduling date of the
Control-D or Control-V decollating mission.

SYSOWNER Current owner.

SYSPDATE Previous scheduling date. Varies, depending on the method by


which Control-M/Analyzer is invoked, as follows:
 If by Control-M/Analyzer rule, the previous day
(meaning, yesterday).
 If by Control-M/Analyzer mission, previous scheduling date
of the Control-M/Analyzer mission.
 If by Control-M, previous scheduling date of the Control-M
production job.
 If by Control-D or Control-V, previous scheduling date of the
Control-D or Control-V decollating mission.

SYSRARGNO Number of rule arguments.

267
Control-M/Analyzer User Guide

Variable Description

SYSRESOLVE* Flag to indicate whether symbols that begin with %% must be


resolved. As a default, AutoEdit variables are resolved
automatically.
Setting SYSRESOLVE to NO overrides this default; this option is
not currently available. See SYSRESOLVE Control Statement (on
page 260).

SYSRC System return code. Can be used to check the results of several
functions (HOWMANY, NEXTVAR, SUM). Valid values:
 0 – The function was successful.
 Other – The function failed. Check the specific rule or user
routine for a list of possible return codes and their
significance.

SYSRRC Return code of a rule called by a DO RULE statement.

SYSRULE Name of the rule to be executed by Control-M/Analyzer.


However, if the rule was called by another rule, the value is the
name of the calling rule.

SYSRUNID* Site-defined run identifier. Run identifiers can be specified as


part of a Control-M/Analyzer Database variable name for
identification purposes. The run identifier can only contain
alphanumeric characters.

SYSRUNMODE Implementation level mode for the current group:


 D—Define mode
 S—Simulate mode
 A—Active mode

SYSSUBRULE Name of the currently executing rule. Eight characters are


returned (meaning, the name is padded with blanks on the right
if necessary).

SYSTIME System time.

SYSURC Return code of a rule called by a DO CALLUSER statement.

SYSVER Control-M/Analyzer version number.

SYSYEAR Year portion of system date (format yy).

268
4
4
Expressions and Functions
This chapter includes the following topics:
 Expressions (on page 271)
• Operators (on page 271)
• Order of Operations (on page 273)
• Operands (on page 274)
• AutoEdit Processing (on page 275)
• Calculation Mode (on page 276)
• Rounding Method (on page 276)
 Functions (on page 277)
• Function Summary (on page 278)
• Function Syntax (on page 281)

269
Control-M/Analyzer User Guide

 ABS: Functions (on page 282)


 CALCDATE: Functions (on page 283)
 CONVDATE: Functions (on page 284)
 DATASTAMP: Functions (on page 286)
 DBINFO: Functions (on page 287)
 DDINFO: Functions (on page 290)
 DDNUM: Functions (on page 292)
 FILTER: Functions (on page 294)
 FILTERW: Functions (on page 296)
 FIND: Functions (on page 298)
 FINDCH: Functions (on page 299)
 GETJUL: Functions (on page 300)
 GETWDAY: Functions (on page 302)
 HOWMANY: Functions (on page 304)
 INT: Functions (on page 306)
 ISDSN: Functions (on page 307)
 ISMEM: Functions (on page 308)
 ISNUMBER: Functions (on page 310)
 ISSYSOUT: Functions (on page 312)
 ISVAR: Functions (on page 314)
 LENGTH: Functions (on page 316)
 LINECOUNT: Functions (on page 317)
 MAX: Functions (on page 318)
 MEMLINES: Functions (on page 320)
 MIN: Functions (on page 322)
 MOD: Functions (on page 324)
 NEXTVAR: Functions (on page 326)
 NOT: Functions (on page 329)
 POW: Functions (on page 330)
 REPLACE: Functions (on page 331)
 SQRT: Functions (on page 333)
 SUBSTR: Functions (on page 334)
 SUM: Functions (on page 336)

270
Control-M/Analyzer User Guide

 TOLER: Functions (on page 338)


 TOLOWER: Functions (on page 340)
 TOUPPER: Functions (on page 341)
 TRIMB: Functions (on page 342)
 TRIML: Functions (on page 343)
 WORD: Functions (on page 344)
 WORDNUM: Functions (on page 346)

Expressions
Control-M/Analyzer expressions provide the capability to compare and initialize variables. Expressions are
composed of operators and operands in the following format:
operand operator operand

The EXECUTE statement allows and the IF statement requires the specification of an expression:
EXECUTE CHECKVAR UPON TOTAL > 0
IF EMPNAME = 'JONES'

Operators
There are four types of operators:
 Arithmetic operators perform calculations (for example, 100*10).
 Standard Comparative operators compare operands and resolve to either true or false (for example, 5
> 4, TOTAL .LT. 100, NAME = ‘SMITH’).
If both operands are numeric, a numeric comparison takes place. If either operand is nonnumeric, the
operands are compared as character strings from left to right.
 Forced Character Comparative operators compare operands as character strings and resolve to either
true or false. These operators start with the letter C.
Forced Character operators specify a character comparison even if both operands are numeric.
Character operands and expressions using Forced Character operators are compared as character
strings from left to right. For example:
91 CGT 1000 resolves to true
(because 9 is greater than 1)
 Boolean Comparative operators evaluate to true or false using Boolean logic operators AND and OR
(for example, 10 > 5 AND 100 > 10). An AND expression evaluates to true if both of its operands
resolve to true. An OR expression evaluates to true if either of its operands resolves to true.
Table 144 lists Control-M/Analyzer operators by type.

271
Control-M/Analyzer User Guide

Table 144 Control-M/Analyzer Operator Types

Operator Type Operator Description

Arithmetic + Addition
- Subtraction
* Multiplication
/ Division

Standard EQ, = Is equal to


Comparative NE, Ø ­ = Is not equal to
GT, > Is greater than
GE, >= Is greater than or equal to
LT, < Is less than
LE, <= Is less than or equal to

Forced Character CEQ Is equal to


Comparative CNE Is not equal to
CGT Is greater than
CGE Is greater than or equal to
CLT Is less than
CLE Is less than or equal to

Boolean AND True if both operands are true


Comparative OR True if either operand is true
Concatenation // Concatenate contents of two
Control-M/Analyzer variables

272
Control-M/Analyzer User Guide

Order of Operations
The Control-M/Analyzer order of operations is the standard natural order of arithmetic expression
evaluation.
Table 145 Control-M/Analyzer Order of Operations

Expression Description

%% AutoEdit variables have the highest priority during resolution.

() Parentheses can be used to override the natural order of operations.

// Two Control-M/Analyzer variables are concatenated.

Functions Control-M/Analyzer functions and their respective input expressions


are resolved.

*,/ Multiplication and division, evaluated from left to right, are resolved.

+,– Addition and subtraction, evaluated from left to right, are resolved.

=, Ø \- =, >, >=, <, Comparison operators are resolved.


<=,
EQ, NE, GT, GE,
LT, LE, CEQ, CNE,
CGT, CGE, CLT, CLE

AND, OR Boolean operators are resolved last.

If a function receives an expression as input, that expression is evaluated (according to the above order
of operations) independently before the original function is evaluated.

273
Control-M/Analyzer User Guide

Operands
A Control-M/Analyzer operand can be a character string, numeric constant, or variable.
Table 146 Control-M/Analyzer Operands

Operand Description

Character String Any string between apostrophes (single quotes); for example, ‘This
is a string’. Do not use an apostrophe within a string. Use two
consecutive single quotes within a string to produce an apostrophe.
Do not use double quotes; for example, "This is not a string". For
more information, see Expression Delimiters (on page 510).

Numeric Constant Any decimal number. A negative sign (for example, –5, –5.01) can
be specified.

Variable Any Control-M/Analyzer Database, AutoEdit, Local, or System


variable. An in-depth explanation of variables is provided in
Control-M/Analyzer Variables (on page 222).

Table 147 Examples of Operands

Expression Evaluates to:

5.0 = 5.0 True

5.0 GT 2.0 True

5.0 > 2.0 True

2.0 GT 5.0 False

‘ABC’ LT ‘XYZ’ True

5 GT 32 False

‘5’ GT ‘32’ False

‘5’ Ø\- = ‘32’ True

5 CGT 32 True

‘5’ CGT ‘32’ True

‘5’ GT 32 False

5 GT ‘32’ False

5 CGT 32 AND 5.0 LT 2.0 False

274
Control-M/Analyzer User Guide

Expression Evaluates to:

5 CGT 32 OR 5.0 LT 2.0 True

5 + 2 7

8 / 2 4

9 / 2 4.5

1 + 2 – 3 * (–4) 15.0

5.5 * SQRT(9) 16.5

(I + J) * 4 where I = 5.5, J = 4 38.0

(I + J) * 4 where I = 5.A, J = 4 Error

1 + 2 LE SQRT(9) True

‘809’ GT ‘303’ True

809 GT 90 True

‘809’ GT ‘90’ True

809 CGT 90 False

809 CGT 90 AND 1 + 2 LE SQRT(9) False

809 CGT 90 OR 1 + 2 LE SQRT(9) True

Note: A numeric value surrounded by single quotes is treated as a numeric value when compared. A
nonnumeric value surrounded by single quotes is treated as a string.

AutoEdit Processing
Expressions can contain variables prefixed by the AutoEdit operator %%. AutoEdit processing makes the
specification of expressions dynamic and flexible.
When Control-M/Analyzer encounters an expression, the contents of the expression are scanned for
special symbols (starting with %%). These symbols are assumed to be variables and are replaced by their
current value. The modified expression is then evaluated.
The AutoEdit operator and the AutoEdit facility and its variables are described in detail in AutoEdit
Variables (on page 256), and AutoEdit Substitution of Database Variables (on page 229).

275
Control-M/Analyzer User Guide

Example
Table 148 AutoEdit Processing Examples

Expression Description

DO SET = %%T=%%TOTAL Sets AutoEdit variable %%T to the value of


AutoEdit variable %%TOTAL.

IF %%TOTAL=100 Determines if the value of AutoEdit variable


%%TOTAL equals 100.

DO PRINT = THE AVERAGE IS %%AVG Prints the Local variable AVG.

Calculation Mode
Control-M/Analyzer performs all arithmetic calculations in floating point mode. The result is always
returned as a floating point number.
Before performing arithmetic calculations, Control-M/Analyzer checks that each operand resolves to a
valid number. If an operand is nonnumeric, the result is a Control-M/Analyzer runtime error.

Rounding Method
Numbers are rounded automatically to the number of decimal places specified in the site default. When
comparing two numbers, Control-M/Analyzer rounds the numbers to the specified precision. Rounding is
suppressed if the site default is set to 99 decimals. For details about changing the default setting, see the
discussion about modifying IOA product defaults in the INCONTROL for z/OS Administrator Guide.
Examples
If precision has been specified to two decimal places:
Table 149 Rounding Method Expression Examples

Expression Evaluates to:

2.4639 = 2.46 True

2.4658 = 2.46 False

2.4639 = 2.4 False

276
Control-M/Analyzer User Guide

Functions
Functions are used to process numeric and character string values within an expression. Input arguments
specify information necessary for a function to operate. Functions return processed values to the rule for
further evaluation and processing.
Functions can perform sophisticated operations. Control-M/Analyzer functions are divided into the
categories described in Table 150.
Table 150 Control-M/Analyzer Functions

Function Description

String Manipulate data strings.

Mathematical Perform mathematical computations on numeric values and


variables.

Variable Provide information about Control-M/Analyzer variables.

Balancing Provide information about Control-M/Analyzer data sources and


other balancing activities.

Date Calculate dates.

JCL Return information contained in the Job Control Language


statements.

Data set Determine if a data set or member exists, or return information


about a PDS member.

Miscellaneous Perform various other operations.

277
Control-M/Analyzer User Guide

Function Summary
The list in Table 151 summarizes Control-M/Analyzer functions by category. Each function and its syntax
are described in detail in alphabetical order on the following pages.
Table 151 Control-M/Analyzer String Functions

Function Description

FILTER Removes all occurrences of specified characters from a data string.

FILTERW Removes one or several occurrences of a string from a data string.

FIND Returns the position of a string within a data string.

FINDCH Returns the position in a data string of the first occurrence of any
one of the characters specified in a substring.

ISNUMBER Determines if its argument is numeric.

LENGTH Determines the number of characters in a data string.

REPLACE Replaces a specified character string with another character string.

SUBSTR Extracts a portion of a data string.

TOLOWER Converts a data string to lowercase characters.

TOUPPER Converts a data string to uppercase characters.

TRIMB Removes (trims) trailing blanks from a data string.

TRIML Removes (trims) leading blanks from a data string.

WORD Returns the nth word (substring) in a string. Delimiters can be


specified as word separators.

WORDNUM Returns a count of the number of words in a string.

278
Control-M/Analyzer User Guide

Table 152 Control-M/Analyzer Mathematical Functions

Function Description

ABS Calculates the absolute value of its numeric argument.

INT Returns the integer portion of its numeric argument.

MAX Returns the largest value in a list of numbers.

MIN Returns the smallest value in a list of numbers.

MOD Returns the remainder that results when its second argument is
divided by its first argument.

POW Calculates the result of raising its first argument to the power of its
second argument.

SQRT Returns the square root of its numeric argument.

SUM Calculates the sum of the variables the names of which match a
specified pattern (mask).

Table 153 Control-M/Analyzer Variable Functions

Function Description

DBINFO Returns information about a Database variable.

HOWMANY Returns the number of variables the names of which match a


specified pattern.

ISVAR Determines if its argument currently exists as a Control-M/Analyzer


Local or Database variable.

NEXTVAR Returns the next variable in a set of variables that match a specified
pattern (mask), thus enabling Control-M/Analyzer to scan the entire
set.

279
Control-M/Analyzer User Guide

Table 154 Control-M/Analyzer Balancing Functions

Function Description

DATASTAMP Returns the unique identifier of a data source specified by a


previously executed EXECUTE block.

LINECOUNT Returns the number of lines of a data source specified by a


previously executed EXECUTE block.

TOLER Determines if the percentage difference between two numbers is


less than or equal to the specified tolerance percentage.

Table 155 Control-M/Analyzer Date Functions

Function Description

CALCDATE Calculates a date by adding or subtracting the number of days in


the second argument to or from the date in the first argument.

CONVDATE Modifies a date format.

GETJUL Returns the Julian calendar date of its date argument.

GETWDAY Returns the day of week of its date argument.

Table 156 Control-M/Analyzer JCL Functions

Function Description

DDINFO Returns information about a data set that is referenced by a specific


DD statement. The information is obtained from the JCL.

DDNUM Returns the number of data sets concatenated in a specific DD


statement. The information is obtained from the JCL.

Table 157 Control-M/Analyzer Data set Functions

Function Description

ISDSN Determines if a data set exists.

ISMEM Determines if a member exists in a specified library.

ISSYSOUT Determines if a SYSOUT exists

MEMLINES Returns the number of lines in a specific member.

280
Control-M/Analyzer User Guide

Table 158 Control-M/Analyzer Miscellaneous Functions

Function Description

NOT Negates the value of its logical argument.

Function Syntax
When specifying functions in a Control-M/Analyzer expression, take the following into consideration:
 Each function returns a value.
 All functions consist of a function name and a set of parentheses. Arguments are specified between
the parentheses. Each function can receive a different number of arguments. Commas are used to
separate arguments listed between parentheses.
FUNCTION(argument1, argument2, ... argumentn)
 No space can exist between the function name and the first parenthesis.
 A function may be passed as an argument to another function. This is called function nesting. When
functions are nested, the innermost function is resolved first. Its value is then passed to the outer
function. There is no limit to the number of nested functions allowed in Control-M/Analyzer
 An expression may be passed as an argument to a function. This type of argument is called a nested
expression. In this case, the innermost expression is resolved first. Its value is then passed to the
function, that is resolved next. The outer expression is resolved last. There is no limit to the number
of nested expressions allowed in Control-M/Analyzer.
Example
FUNCTION(FUNCTION(ARGUMENT1))

281
Control-M/Analyzer User Guide

ABS: Functions
Calculates the absolute value of its numeric argument.
Figure 130 ABS Format

Syntax
ABS(value)

where value is a valid numeric expression.

General Information
ABS returns the absolute value of the value or expression between its parentheses. This function can be
used to determine the nonnegative difference between two numbers.

Examples
Table 159 ABS Function Examples

Function Returns value:

ABS(5) 5

ABS(-5) 5

ABS(100-50) 50

ABS(50-100) 50

282
Control-M/Analyzer User Guide

CALCDATE: Functions
Calculates a date by adding or subtracting the number of days in the second argument to or from the
date in the first argument.
Figure 131 CALCDATE Function Format

Syntax
CALCDATE(argument1,argument2)

where

 argument1 is a valid date specification in yymmdd format


 argument2 is a positive or negative number indicating the number of days to add to or subtract from argument1

General Information
The CALCDATE function provides arithmetic capabilities for date operations. Days can be added or subtracted to the
specified date. The returned date is in yymmdd format.

Examples
Table 160 CALCDATE Function Examples

Function Returns value:

CALCDATE(000505,5) 0090510

CALCDATE(000510,-5) 000505

CALCDATE(001231,1) 010101

CALCDATE(001001,-30) 000901

CALCDATE(001231,13) 010113

283
Control-M/Analyzer User Guide

CONVDATE: Functions
Modifies a date format. The function has three arguments: an AutoEdit variable containing the date to be
modified, a mask specifying the input format, and a mask specifying the output format.
Figure 132 CONVDATE Function Format

Syntax
CONVDATE(date,'format-in','format-out')

In this syntax
 date is a AutoEdit variable containing the source date to be converted.
 format-in is the maximum 8 character input date mask. The day, month, and year are represented by
MM, DD, and YY, respectively, separated by the actual symbols used in the input. For example,
‘DD/MM/YY’.
 format-out is the maximum 8-character output date mask. The day, month, and year are represented
by DD, MM, and YY, respectively, separated by the symbols desired in the output. For example,
‘YY.MM.DD’.

General Information
The CONVDATE function returns a date in the specified output format. It is not necessary for the input
and output formats to contain the same elements. For example, the output format may consist of month
and year even though the input contains year, month, and day. Conversely, if the output format consists
of day, month and year, but the input contains only day and month, the year position in the output will
contain YY.

284
Control-M/Analyzer User Guide

Examples
Table 161 CONVDATE Function Examples

Function Returns value

CONVDATE('30/05/00','DD/MM/YY','MM/DD/YY') 05/30/00

CONVDATE('30/05/00','DD/MM/YY','YY/MM/DD') 00/05/30

CONVDATE('30/05/00','DD/MM/YY','MM.DD.YY') 05.30.00

CONVDATE('30/05/00','DD/MM/YY','YY-MM-DD') 00-30-05

CONVDATE('30/05/00','MM/YY','YY-DD-MM') 05-DD-30

CONVDATE('30/05/00','YY','YY-DD-MM') 30-DD-MM

CONVDATE('30/05/00',' ','YY-DD-MM') YY-DD-MM

CONVDATE('30/05/00','DD/MM/YY',' ') [blank]

CONVDATE('30/05/00','DD/MM/YY','MM-YY') 05-00

285
Control-M/Analyzer User Guide

DATASTAMP: Functions
Returns the unique identifier of a data source specified by a previously executed EXECUTE block.
Figure 133 DATASTAP Function Format

Syntax
DATASTAMP(block)

In this syntax, block is the name of an EXECUTE block in the current rule that (according to rule
processing flow order) has already been processed. The EXECUTE block can contain any ON statement
(data source) type except ON DATA.

General Information
If a unique DATASTAMP identifier was calculated and assigned to the data source, the DATASTAMP
function returns this identifier. If a datastamp was not calculated, the DATASTAMP function returns 0
(zero).
This function can be used to determine if the contents of a file have changed. After file creation, save the
value returned by the DATASTAMP function in the Control-M/Analyzer Database. Before processing the
file, compare its current datastamp value to the value stored in the Database. For information about
creating datastamps, see Datastamp Calculation (on page 442).

286
Control-M/Analyzer User Guide

Examples
Table 162 DATASTAMP Function Examples

Function Returns value:

DATASTAMP(MAINFILE) 58A1

DTAMP(MAINFILE)=DB_LASTSTAMPwhee TRUE
B_LASTSTAMP is 58A1

287
Control-M/Analyzer User Guide

DBINFO: Functions
Returns information about a Database variable.
Figure 134 DBINFO Function Format

Syntax
DBINFO(variable,type)

In this syntax
 variable is the existing Control-M/Analyzer Database variable name, or an expression that resolves to
an existing Control-M/Analyzer Database variable name. Must be in quotes. Mandatory.
 type is the type of information requested. Must be in single quotes. Mandatory. Available types:
• GEN – Current generation of the variable. If the variable has not been committed, –1 is returned.
• KEY – Key of the variable.
• RUNID – Run ID of the variable.
• TIME – Creation time of the variable.
• DATE – Creation date of the variable.

General Information
The DBINFO function returns a number, date, or data string, depending on the type of information
requested.

288
Control-M/Analyzer User Guide

Examples
Assume the following information for the examples below:
Table 163 Values for DBINFO Function Examples

Database Variable Generation Key RunID Time Data

DB_CHKDBL1 +0 VAL1 RNID1 21:44 03/03/00

DB_CHKDBL1 +1 VAL3 RNID3 10:15 02/02/00

DB_CHKDBL1 +2 VAL2 RNID2 08:00 01/01/00

DB_CHKDBL2 Not
committed L3 R05 14:15 05/05/00

DB_CHKDBL3 +0 M4 000202 18:10 02/02/00

DB_CHKDBL3 +1 M5 000101 20:15 01/01/00

Table 164 DBINFO Function Examples

Function Returns value:

DBINFO('DB_CHKDBL2','GEN') -1

DBINFO('DB_CHKDBL3@KM5','GEN') +1

DBINFO('DB_CHKDBL1@RRNID2','GEN') +2

DBINFO('DB_CHKDBL1@G0','KEY') VAL1

DBINFO('DB_CHKDBL1@G0','RUNID') RNID1

DBINFO('DB_CHKDBL1@G1','TIME') 10:15

DBINFO('DB_CHKDBL1@G1','DATE') 02/02/00

289
Control-M/Analyzer User Guide

DDINFO: Functions
Returns information about a data set that is referenced by a specific DD statement. The information is
obtained from the JCL.
Figure 135 DDINFO Function Format

Syntax
DDINFO(procstep,pgmstep,DD_statement,integer,type)

In this syntax
 procstep is the name of the procedure step. Must be in quotes. If the step does not exist, a blank
must be specified. Mandatory.
 pgmstep is the name of the program step. Must be in quotes. If the step does not exist, a blank must
be specified. Mandatory.
If the program step is the current step, character * can be specified instead of the full name of the
program step.
 DD_statement is the name of the DD statement. Must be in quotes. Mandatory.
 integer is the position of the data set as concatenated in the DD statement. If only one data set is
listed, the number 1 should be specified. Mandatory.
 type is the type of information requested. Mandatory. Must be in quotes. Available types are:
• DSN—Data set name.
• MEM—Member name.
• GEN—Data set generation number.

290
Control-M/Analyzer User Guide

Example
Assume the following JCL for these examples:
Figure 136 JCL for DDINFO Function Example
//STEP1 EXEC PGM=IEBCOPY
//SYSPRINT DD SYSOUT=*
//I1 DD DSN=PROD.FILE.TEST1,DISP=SHR
//O1 DD DSN=TAPE.TEST1,DISP=(NEW,PASS),
// VOL=SER=TAPE1,UNIT=TAPE,LABEL=(1,SL)
//STEP2 EXEC CONTROLB,RULE=RULE1
//TSTDSN1 DD DSN=M01.EXAMP.LIBR,DISP=SHR
// DD DSN=M02.ISPF.ISPPROF(MEMNAME),
// DISP=SHR
// DD DSN=M01.TEXT.LIBR(+1),DISP=SHR
//TSTDSN2 DD DSN=M03.TEXT.LIB1,DISP=SHR

Table 165 DDINFO Function Example

Function Returns value:

DDINFO('*','*','TSTDSN1',2,'MEM') MEMNAME

DDINFO('*','*','TSTDSN1',1,'DSN') M01.EXAMP.LIBR

DDINFO('*','*','TSTDSN1',3,'GEN') +1

DDINFO('STEP2','*','TSTDSN2',1,'DSN') M03.TEXT.LIB1

DDINFO(' ','STEP1','I1',1,'DSN') PROD.FILE.TEST1

Return Codes
The SYSRC system variable is set to one of the return codes described in Table 166.
Table 166 DDINFO Return Codes Passed to System Variable SYSRC

Code Description

0 The requested information was obtained.

4 No stepname or no ddname in the JCL satisfied the specified


criteria.

8 The specified integer (data set position) exceeds the number of data
sets referenced by the specified DD statement.

291
Control-M/Analyzer User Guide

DDNUM: Functions
Returns the number of data sets concatenated in a specific DD statement. The information is obtained
from the JCL.
Figure 137 DDNUM Function Format

Syntax
DDNUM(procstep,pgmstep,DD-statement)

In this syntax
 procstep is the name of the procedure step. Must be in quotes. If the step does not exist, a blank
must be specified. Mandatory.
If the procedure step is the current step, an asterisk ( * ) can be specified instead of the full name of
the procedure step.
 pgmstep is the name of the program step. Must be in quotes. If the step does not exist, a blank must
be specified. Mandatory.
If the program step is the current step, an asterisk ( * ) can be specified instead of the full name of
the program step.
 DD-statement is the name of the DD statement. Must be in quotes. Mandatory.

292
Control-M/Analyzer User Guide

Example
Assume the following JCL for this example:
Figure 138 JCL for DDNUM Example
// EXEC CONTROLB,RULE=RULE1
//TESTDSN DD DSN=M01.EXAMP.LIBR,DISP=SHR
// DD DSN=M02.ISPF.ISPPROF(MEMNAME),
// DISP=SHR
// DD DSN=M01.TEXT.LIBR(+1),DISP=SHR
//TSTDSN DD DSN=M03.TEXT.LIB1,DISP=SHR

Table 167 DDNUM Function Example

Function Returns value:

DDNUM('*','*','TESTDSN') 3

293
Control-M/Analyzer User Guide

FILTER: Functions
Removes all occurrences of specified characters from a data string.
Figure 139 FILTER Function Format

Syntax
FILTER(string,filter)

In this syntax
 string is the expression that evaluates to a data string. Mandatory.
 filter is the expression that evaluates to a data string. Mandatory.

General Information
The FILTER function returns a data string equivalent to the original string minus occurrences of each
character in filter. FILTER works on data strings only.

294
Control-M/Analyzer User Guide

Examples
Table 168 FILTER Function Examples

Function Returns value:

FILTER('RULE DEFINITION',' ') RULEDEFINITION

FILTER('1,2,3,4,5',',') 12345

FILTER('ADM_BKP_REPTS','_') ADMBKPREPTS

FILTER(DB_EMP,DB_INITIAL) OYGODON
where DB_EMP = 'ROY R. GORDON'
and DB_INITIAL = ' R.'

295
Control-M/Analyzer User Guide

FILTERW: Functions
Removes one or several occurrences of a substring (for example, a word) from a data string.
Figure 140 FILTERW Function Format

Syntax
FILTERW(strng,substrng,firstOccur,lastOccur)

In this syntax
 strng is the data string (enclosed in quotes) or variable with a value that is a string, from which an
occurrences of a substring is to be removed. Mandatory.
 substrng is the data string (enclosed in quotes) or variable with a value that is a substring (that
represents a word). One or more occurrences of this substring will be removed from strng.
Mandatory.
 firstOccur is an integer that represents an occurrence, or the first of several occurrences, of substrng,
that is to be removed from strng. Optional. The default value is 1.
 lastOccur, in the case if firstOccur is specified, can be specified as an integer that represents the last
occurrence of the substring to be removed from strng. Optional. The default value is the first
occurrence.

General Information
The FILTERW function returns a data string equivalent to the original string minus the occurrences of a
substring, that is usually a word.
This function differs from function FILTER (described above) in that the second argument (the substring
to be removed) is treated as a unit. Characters in the second argument are only removed from the first
argument (the original string) when they occur in sequential order. Characters in the second argument
are not removed from the original string individually.

296
Control-M/Analyzer User Guide

Examples
Note: Both function FILTER and function FILTERW are illustrated to clarify the differences between them.
Table 169 FILTERW Function Examples

Function Returns value:

FILTER('TOTALS','T') OALS

FILTERW('TOTALS','T') OTALS

FILTER('TOTALS','TO') ALS

FILTERW('TOTALS','TO') TALS

FILTER('MULTIPLICATION','TI') MULPLCAON

FILTERW('MULTIPLICATION','TI',2) MULTIPLICAON

FILTERW('1-800-555-1212','-',2,3) 1-8005551212

FILTERW('05/18/2000, 05/22/2000, 05/18/00, 05/22/00, 05/22/00


05/22/2000','20',2,4)

297
Control-M/Analyzer User Guide

FIND: Functions
Returns the position of a substring within a data string.
Figure 141 FIND Function Format

Syntax
FIND (strng,substrng,occurrence)

In this syntax
 strng is a data string (enclosed in quotes) or variable with a value that is a string. Mandatory.
 substrng is a data string (enclosed in quotes) or variable with a value that is a string. strng is
searched for an occurrence of substrng. Mandatory.
 occurrence is an integer, or a Control-M/Analyzer variable containing an integer value, representing
the occurrence of substrng that should be located. Optional. If occurrence is not specified, the
position of the first occurrence is returned.

General Information
Returns the starting position of substrng within strng, or 0 if substrng is not found within strng.

298
Control-M/Analyzer User Guide

Examples
Table 170 FIND Function Examples

Function Returns value:

FIND('DEC. 15, 2000','15') 6

FIND('JANET CAMDEN, MD','MD',2) 15

FINDCH: Functions
Returns the starting position in a data string of the first occurrence of any one of the characters specified
in a list of characters.
Figure 142 FINDCH Function Format

Syntax
FINDCH(inputString,charList)

where
 inputString is a data string (enclosed in quotes) or variable with a value that is a string, in that the
first occurrence of a character (in the string charList) is to be located. Mandatory.
 charList is a character string (enclosed in quotes) or variable with a value that is a string, the first
occurrence of any character of which is to be located in inputString. Mandatory.

General Information
If none of the characters in charList occurs in inputString, 0 (zero) is returned.

299
Control-M/Analyzer User Guide

Examples
Table 171 FINDCH Function Examples

Function Returns value:

FINDCH('123','21') 1

FINDCH('S,M,L,XL','LZ') 5

FINDCH('1-800-555-1212','34679') 0

GETJUL: Functions
Returns the Julian calendar date of its date argument.
Figure 143 GETJUL Function Format

Syntax
GETJUL(date)

where date is a valid date in yymmdd format.

General Information
The GETJUL function returns a numeric value that is the Julian calendar date that corresponds to the date
argument.

300
Control-M/Analyzer User Guide

Examples
Table 172 GETJUL Function Examples

Function Returns value:

GETJUL(000201) 32

GETJUL(000101) 1

GETJUL(001231) 366

301
Control-M/Analyzer User Guide

GETWDAY: Functions
Returns an integer from 0 through 6 indicating the day of the week of its date argument.
Figure 144 GETWDAY Function Format

Syntax
GETWDAY(date)

where date is a valid date in yymmdd format.

General Information
The GETWDAY function returns a number representing the day of week on which the date in the date
argument falls. The first day of the week, as specified in the SWEEK IOA installation parameter, is
designated by the number 1. The last day of the week is designated by the number 0.
If the value of the SWEEK IOA installation parameter is MON (Monday), the integers 0 through 6
represent Sunday through Saturday. If the value of SWEEK is SUN (Sunday), the integers 0 through 6
represent Saturday through Friday.

302
Control-M/Analyzer User Guide

Example
In the examples in Table 173, the first day of the week is the SWEEK IOA installation parameter default:
Monday. Therefore, Monday=1, Tuesday=2, ..., Saturday 6, Sunday=0.
Table 173 GETWDAY Function Examples

Function Returns value:

GETWDAY(001220) 3

GETWDAY(000101) 6

GETWDAY(000222) 2

GETWDAY('ABCDEF') Error

303
Control-M/Analyzer User Guide

HOWMANY: Functions
Returns the number of variables with names that match a specified pattern (mask).
Figure 145 HOWMANY Function Format

Syntax
HOWMANY(varList)

In this syntax, varList represents a set of variable names. varList can be a Local variable name, a
Database variable name, or a mask that represents several Local variable names. Must be in quotes.
Mandatory.

General Information
The HOWMANY function returns the total number of Control-M/Analyzer Local and Database variables
that match the mask specified in varList.
Mask characters are supported for Local variable names in varList. varList may contain an asterisk * (that
represents any number of characters) or a question mark ? (that represents a single character).
Mask characters are not supported for Database variables in varList.
Uncommitted Database variables that satisfy the criteria specified are considered (meaning, they are
taken into account even though they are not yet committed).

304
Control-M/Analyzer User Guide

Examples
Assume the following for the examples below:
Table 174 Values for HOWMANY Function Examples

Variable Name Key Value

A1 2,

A2 2.5,

A3B 3,

DB_CHKDBL@G0 03 DATA1

DB_CHKDBL@G1 01 TESTDATA

DB_CHKDBL@G2 11 ABCD

DB_CHKDBL@G3 01 2

DB_CHKDBL 01 1 (not yet committed)

Table 175 HOWMANY Function Example

Function Returns value:

HOWMANY('A*') 3

HOWMANY('A?') 2

HOWMANY('DB_CHKDBL') 5

HOWMANY('DB_CHKDBL@K01') 3

305
Control-M/Analyzer User Guide

INT: Functions
Returns the integer portion of its argument.
Figure 146 INT Function Format

Syntax
INT(value)

where value is a number (with a fractional portion).

General Information
The fractional portion of the number is ignored. The integer portion of the number is returned.

Examples
Table 176 INT Function Examples

Function Returns value:

INT(3.65) 3

INT(0.1111) 0

INT(.123) 0

INT(1977.65) 1977

INT('Rule') Error

INT(21) 21

306
Control-M/Analyzer User Guide

ISDSN: Functions
Determines if a data set exists.
Figure 147 ISDSN Function Format

Syntax
ISDSN(dataset)

where dataset is a data set name. Must be in quotes. Mandatory.


The ISDSN function returns the value TRUE if the data set exists, and the value FALSE if the data set
does not exist.

Examples
Assume the following for the examples below:

307
Control-M/Analyzer User Guide

Table 177 Values for ISDSN Function Examples

Data set Name Status

APPL1.EMPLOYEE.FILE Exists

APPL1.PAYROLL.FILE Does not exist

Table 178 ISDSN Function Examples

Function Returns value:

ISDSN (‘APPL1.AMPLOYEE.FILE’) True

ISDSN (‘APPL1.PAYROLL.FILE’) False

ISMEM: Functions
Determines if a specified member exists in a specified library.
Figure 148 ISMEM Function Format

Syntax
ISMEM(library,member)

where
 library is a library name. Must be in quotes. Mandatory.
 member is a member name. Must be in quotes. Mandatory.

308
Control-M/Analyzer User Guide

General Information
The ISMEM function returns the value TRUE if the member exists in the library and the value FALSE if
either the library does not exist or the member does not exist in the library.

Examples
Table 179 Values for ISMEM Function Examples

Member Exists in
Library Member Library Exists? Library?

CTM.PROD.SYMBOLS TAPES Yes Yes

CTM.PROD.SYMBOLS BOOKS Yes No

APPL1.PYROL.FILE No

Table 180 ISMEM Function Examples

Function Returns value:

ISMEM('CTM.PROD.SYMBOLS','TAPES') True

ISMEM('CTM.PROD.SYMBOLS','BOOKS') False

ISMEM('APPL1.PYROL.FILE','SALARIES') False

309
Control-M/Analyzer User Guide

ISNUMBER: Functions
Determines if its argument is numeric.
Figure 149 ISNUMBER Function Format

Syntax
ISNUMBER(argument)

where argument is any Control-M/Analyzer expression. Mandatory.

General Information
The ISNUMBER function returns TRUE if argument is numeric and FALSE if argument is not numeric.

310
Control-M/Analyzer User Guide

Examples
Table 181 ISNUMBER Function Examples

Function Returns value:

ISNUMBER(100) TRUE

ISNUMBER('RULE DEFINITION SCREEN') FALSE

ISNUMBER(DB_CURRENT_EMP) FALSE
where DB_CURRENT_EMP=‘Barbara
Gordon’

ISNUMBER(DB_CURR_TOTAL) TRUE
where DB_CURR_TOTAL=550

ISNUMBER('2.45') TRUE

ISNUMBER('2.45 F') FALSE

ISNUMBER(' 2.45') TRUE

ISNUMBER(' 2.4 5') FALSE

ISNUMBER('') Syntax Error

ISNUMBER(' ') FALSE

311
Control-M/Analyzer User Guide

ISSYSOUT: Functions
Determines if a sysout exists.
Figure 150 ISSYSOUT Function Format

Syntax
ISSYSOUT('ddname','procstep','pgmstep','jobname')

In this syntax
 ddname is the name of the DD statement that references the sysout. Must be in quotes. Mandatory.
 procstep is the name of the procedure step that produced the sysout. Must be in quotes. Optional.
 pgmstep is the name of the program step that produced the sysout. Must be in quotes. Optional.
 jobname is the name of the job that produced the sysout. Must be in quotes. Optional. If JOBNAME is
not specified, the default value is the current job.
The ISSYSOUT function returns the value TRUE if the sysout exists and the value FALSE if the sysout does
not exist. This enables you to avoid an attempt to access a nonexistent sysout and thereby avoid an
abend with the return code 4091 when the sysout is not found on spool.
The four arguments are identified by position. A blank argument is represented by one or more blanks
enclosed by quote marks.

312
Control-M/Analyzer User Guide

Examples
Assume the following for the example in Table 182.
Table 182 Values for ISSYSOUT Function Examples

Procedure
DD Statement Step Program Step Job Name Status

DDACTG1 ACTGSTP5 ACTREC2 Exists

DDINVT2 PROCOUT PGMSTP3 MNTHLY Does not exist

Table 183 ISSYSOUT Function Examples

Function Returns

ISSYSOUT('DDACTG1',' ','ACTGSTP5','ACTREC2') True

ISSYSOUT('DDINVT2','PROCOUT','PGMSTP3','MNTHLY') False

313
Control-M/Analyzer User Guide

ISVAR: Functions
Determines if its argument exists as a Control-M/Analyzer Local or Database variable.
Figure 151 ISVAR Function Format

Syntax
ISVAR(varName)

where varName is the name of a Control-M/Analyzer Local or Database variable.

General Information
ISVAR returns TRUE if varName is an existing Control-M/Analyzer Local or Database variable and FALSE if
no Local or Database variable exists with the name varName.

314
Control-M/Analyzer User Guide

Examples
Table 184 ISVAR Function Examples

Function Returns value:

ISVAR(INVTOT) TRUE
where INVTOT is an existing
Control-M/Analyzer local variable.

ISVAR(TOTAL) FALSE
where TOTAL is not an existing
Control-M/Analyzer local variable.

ISVAR(DB_QC.TOTAL) TRUE
where DB_QC.TOTAL is defined in the
Control-M/Analyzer Database.

ISVAR(DB_QC.TOTAL@KJAN) TRUE
where the Database variable TOTAL of
group QC has a generation with a user
key of JAN.

315
Control-M/Analyzer User Guide

LENGTH: Functions
Determines the number of characters in a data string.
Figure 152 LENGTH Function Format

Syntax
LENGTH(strng)

where strng is a String or expression that evaluates to a data string. Mandatory.

General Information
The LENGTH function returns a number that indicates the number of characters, including spaces, in
strng.

Examples
Table 185 LENGTH Function Examples

Function Returns value:

LENGTH('AB') 2

LENGTH('RULE DEFINITION SCREEN') 22

LENGTH('TOTALS: $ 15000') 16

LENGTH(DB_CURRENT_EMP) 14
where DB_CURRENT_EMP='BARBARA GORDON'

LENGTH(' BLANKS ARE COUNTED ') 20

316
Control-M/Analyzer User Guide

LINECOUNT: Functions
Returns the number of lines of a data source specified by a previously executed EXECUTE block.
Figure 153 LINECOUT Function Format

Syntax
LINECOUNT(executeBlock)

In this syntax, executeBlock is the name of an EXECUTE block in the current rule that (according to rule
processing flow order) has already been processed. The ON statement in the EXECUTE block can specify
any data source type except DATA.

General Information
The LINECOUNT function returns the number of lines that exist in the data source processed by the
specified EXECUTE block.
The number of lines is counted by Control-M/Analyzer when the EXECUTE block is executed. The line
count of data sources specified by EXECUTE blocks that have not yet been processed is not known.
Therefore, LINECOUNT returns 0 if the specified EXECUTE block has not been processed.

Example
Table 186 LINECOUNT Function Example

Function Returns value:

LINECOUNT(lastBlock) 500
where lastBlock had 500 lines when last executed during
the rule invocation.

317
Control-M/Analyzer User Guide

MAX: Functions
Returns the largest value in a list of numbers.
Figure 154 MAX Function Format

Syntax
MAX(number1,number2,...,number-n)

In this syntax, number1,number2,...,number-n are numbers, variables with values that are numeric, or
Control-M/Analyzer expressions that resolve to numeric values. At least two numbers must be specified.

General Information
An unlimited number of numbers can be specified.

318
Control-M/Analyzer User Guide

Examples
Assume the following for the examples below:
Table 187 Values for MAX Function Examples

Variable Value

SALARY_1 5660

SALARY_2 7122.50

Table 188 MAX Function Examples

Function Returns value:

MAX(3,9,4.25) 9

MAX(5200,SALARY_1,SALARY_2) 7122.50

319
Control-M/Analyzer User Guide

MEMLINES: Functions
Returns the number of lines in a specified member.
Figure 155 MEMLINES Function Format

Syntax
MEMLINES(library,member)

In this syntax
 library is a library name. Mandatory.
 member is a member name. Mandatory.

General Information
The MEMLINES function returns the number of lines that a member contains. The number of lines is
obtained from the ISPF statistics SIZE parameter. The input arguments can be variables or literals,
meaning, character strings enclosed by apostrophes (single quotes).
An error message is generated if the library or member does not exist.

320
Control-M/Analyzer User Guide

Example
Assume that only the following lines exist in member RUNJOB of the APPL.PROD.JCL library:
Figure 156 Sample Member RUNJOB for MEMLINES Function Example
000001 *************************************************
000002 * *
000003 * THIS IS A SAMPLE OF THE TEXT IN A MEMBER. *
000004 * *
000005 * THIS TEXT IS BEING USED TO ILLUSTRATE *
000006 * THE USAGE OF FUNCTION MEMLINES. *
000007 * *
000008 *************************************************

Table 189 MEMLINES Function Example

Function Returns value:

MEMLINES('APPL.PROD.JCL','RUNJOB') 8

321
Control-M/Analyzer User Guide

MIN: Functions
Returns the smallest value in a list of numbers.
Figure 157 MIN Function Format

Syntax
MIN(number1,number2,...,number-n)

In this syntax, number1,number2,...,number-n are numbers, or variables with values that are numeric, or
Control-M/Analyzer expressions that resolve to numeric values. At least two numbers must be specified.

General Information
An unlimited number of numbers can be specified.

322
Control-M/Analyzer User Guide

Examples
Assume the following for the examples below:
Table 190 Values for MIN Function Example

Variable Value

SALARY_1 5660

SALARY_2 7122.50

Table 191 Values for MIN Function Example

Function Returns value:

MIN(3,9,4.25) 3

MIN(5200,SALARY_1,SALARY_2) 5200

323
Control-M/Analyzer User Guide

MOD: Functions
Returns the remainder that results when its first argument is divided by its second argument.
Figure 158 MOD Function Format

Syntax
MOD(integer1,integer2)

In this syntax
 integer1 is the dividend (numerator to be divided by integer2).
 integer2 is the divisor (denominator to divide into integer1).

General Information
The MOD function works on integers only. MOD divides integer1 by integer2. The remainder resulting
from the division is returned by MOD.

324
Control-M/Analyzer User Guide

Examples
Table 192 MOD Function Examples

Function Returns value:

MOD(7,2) 1

MOD(6,2) 0

MOD(2,6) 2

MOD(100,10) 0

MOD(60,6) 0

MOD('ABC',3) Error

MOD('333','3') 0

MOD(4.4,2) Error

MOD(7,0) Error (division by zero)

325
Control-M/Analyzer User Guide

NEXTVAR: Functions
Returns the next variable in a specified set of Local or Database variables, thus enabling
Control-M/Analyzer to scan the entire set.
Figure 159 NEXTVAR Function Format

Syntax
NEXTVAR(varSet,startVar)

In this syntax
 varSet is an expression that resolves to a string that represents a set of variables. varSet can be a
Database variable or a mask for a collection of Local variables. Mandatory.
 startVar is an expression that resolves to a string that represents the name of the Local variable or
Database variable generation from which scanning should start. Can be blank. Optional.

General Information
Local variables are retrieved in alphabetical order. Database variables are retrieved by generation, from
the most recent to the oldest.
 If startVar is blank, NEXTVAR returns the name of the first variable in the set.
 If startVar is the name of a variable in the set, NEXTVAR returns the name of the next variable in the
set. For committed Database variables, the generation is appended to the name.
 If startVar is the name of the last variable in the set, NEXTVAR returns a blank and the SYSRC System
variable is set to 4.
• Mask characters are supported for Local variable names in varset. varset may contain an asterisk
* (that represents any number of characters) or a question mark ? (that represents a single
character).
• Mask characters are not supported for Database variables in varset.

326
Control-M/Analyzer User Guide

• Uncommitted Database variables that belong to the set are returned before committed Database
variables in the same set.

Return Codes
The SYSRC system variable is set to one of the following return codes:
Table 193 NEXTVAR Return Codes Passed to System Variable SYSRC

Code Description

0 Successful execution.

4 Startvar is the last variable that matches the specified criteria.

8 No variables match the specified criteria.

Examples
For the examples below, four Local variables and four generations of a Database variable were created in
the order listed:
Table 194 Values for NEXTVAR Function Examples

Variable Run ID

TOTALD40

TOTALA20

TOTALZ18

TOTALC18

DB_DEMO.CHKDBL@G2 1

DB_DEMO.CHKDBL@G1 2

DB_DEMO.CHKDBL@G0 1

DB_DEMO.CHKDBL (not yet committed) 2

327
Control-M/Analyzer User Guide

Table 195 NEXTVAR Function Examples

Function Returns values

NEXTVAR('TOTAL*') 'TOTALA20'

NEXTVAR('TOTAL*','TOTALA20') 'TOTALC18'

NEXTVAR('TOTAL*','TOTALC18') 'TOTALD40'

NEXTVAR('TOTAL*','TOTALD40') 'TOTALZ18'

NEXTVAR('TOTAL*','TOTALZ18') ' '

DO SET CURRENT=NEXTVAR('TOTAL*',' ') 'TOTALA20'

DO SET CURRENT=NEXTVAR('TOTAL*',CURRENT) 'TOTALC18'

NEXTVAR('DB_CHKDBL',' ') 'DB_CHKDBL'

NEXTVAR('DB_CHKDBL','DB_CHKDBL') 'DB_CHKDBL@G0'

NEXTVAR('DB_CHKDBL','DB_CHKDBL@G0') 'DB_CHKDBL@G1'

NEXTVAR('DB_CHKDBL','DB_CHKDBL@G1') 'DB_CHKDBL@G2'

NEXTVAR('DB_CHKDBL@R1','DB_CHKDBL') 'DB_CHKDBL@G0'

NEXTVAR('DB_CHKDBL@R1','DB_CHKDBL@G0') 'DB_CHKDBL@G2'

328
Control-M/Analyzer User Guide

NOT: Functions
Negates the value of its logical argument.
Figure 160 NOT Function Format

Syntax
NOT(expression)

In this syntax, expression is any expression that resolves to true or false.

General Information
The NOT function returns the logical value opposite to the logical value specified by expression.

Examples
Table 196 NOT Function Examples

Function Returns value:

NOT(1) FALSE

NOT(0) TRUE

NOT(5>10) TRUE

NOT(5<10) FALSE

329
Control-M/Analyzer User Guide

POW: Functions
Calculates the result of raising its first argument to the power of its second argument.
Figure 161 POW Function Format

Syntax
POW(val,pow)

In this syntax

 val is any numeric value or expression.


 pow is any integer (positive, 0, negative).

General Information
The POW function returns the result of raising val to the power specified by pow.

Examples
Table 197 POW Function Examples

Function Returns value:

POW(3,2) 9

POW(2,3) 8

POW(0,1) 0

POW(1,0) 1

POW(8,0) 1

POW(0,0) 1

POW(2,-3) 0.125

330
Control-M/Analyzer User Guide

REPLACE: Functions
Replaces one character string with another.
Figure 162 REPLACE Function Format

Syntax
REPLACE(strng,string1,string2,firstOccur,lastOccur)

where
 strng is a character string (or variable with a value that is a character string). Mandatory.
 string1 is a character string (or variable with a value that is a character string) that is to be replaced
by string2 in strng. Mandatory.
 string2 is a character string (or variable with a value that is a character string) that is to replace
string1 in strng. Mandatory.
 firstOccur is an Integer value that represents an occurrence, or the beginning of a range of
occurrences, of string1 that is to be replaced by string2. Optional. When firstOccur is omitted, the first
occurrence of string1 is replaced by string2.
 lastOccur, if firstOccur has been specified, can be specified as an integer that represents the last
occurrence in a range of occurrences of string1 that is to be replaced by string2. Optional. The default
value is the value of argument firstOccur.

331
Control-M/Analyzer User Guide

Examples
Assume INFO is a variable that contains the string TESTDATA.
Table 198 INFO Function Examples

Function Returns value:

REPLACE(INFO,'A','F') TESTDFTA

REPLACE(INFO,'A','B',2) TESTDATB

REPLACE(INFO,'A','B',1,2) TESTDBTB

REPLACE(INFO,'A','FF',1,3) TESTDFFTFF

REPLACE(INFO,'DATA','XXXXX') TESTXXXXX

332
Control-M/Analyzer User Guide

SQRT: Functions
Returns the square root of its numeric argument.
Figure 163 SQRT Function Format

Syntax
SQRT(value)

where value is a number or an expression that resolves to a numeric value.

General Information
The SQRT function returns the square root of value. If value is negative, SQRT returns zero.

333
Control-M/Analyzer User Guide

Examples
Table 199 SQRT Function Examples

Function Returns value:

SQRT(9) 3

SQRT(3) 1.732

SQRT(48*3) 12

SQRT('Rule') Error

SQRT(-9) 0

SQRT(1.25) 1.118

SUBSTR: Functions
Extracts part of a data string.
Figure 164 SUBSTR Function Format

Syntax
SUBSTR(pos,len,strng)

In this syntax
 pos is a number representing the starting character position from which to extract. Mandatory.
 len is a number representing the number of characters to extract. Mandatory.
 strng is an expression that evaluates to a data string. Mandatory.

334
Control-M/Analyzer User Guide

General Information
The SUBSTR function extracts the number of characters in its second argument (len) from the data string
in its third argument (strng) beginning with the character position in its first argument (pos). SUBSTR
works on data strings only.
The first position in the string is position 1. Use the LENGTH function to determine the last position in the
string.

Examples
Table 200 SUBSTR Function Examples

Function Returns value:

SUBSTR(2,3,'ABCDEFG') 'BCD'

SUBSTR(1,4,'RULE DEFINITION') 'RULE'

SUBSTR(11,5,'EMPLOYEE: JONES') 'JONES'

SUBSTR(10,1,'TOTALS: $15000') '1'

SUBSTR(1,9,DB_EMP) 'BARBARA G'


where DB_EMP = 'BARBARA GORDON'

335
Control-M/Analyzer User Guide

SUM: Functions
Calculates the sum of the variables with names that match a specified pattern.
Figure 165 SUM Function Format

Syntax
SUM(varList)

where varList represents a set of variables. varList can be a Local variable, a Database variable, or a mask
that represents several Local variables. Must be in quotes. Mandatory.

General Information
The SUM function calculates the sum of the values of the variables with names that match the pattern.
The value in each variable must be numeric.
Mask characters are supported for Local variable names in varlist. varlist can contain an asterisk * (that
represents any number of characters) or a question mark ? (that represents a single character).
Mask characters are not supported for Database variables in varlist.
Uncommitted Database variables that satisfy the criteria specified are considered (meaning, even though
they are not yet committed, they are included in the sum).

Return Codes
The SYSRC System variable is set to one of the following return codes:

336
Control-M/Analyzer User Guide

Table 201 SUM Return Codes Passed to System Variable SYSRC

Code Description

0 The function is successful.

8 No variables match the specified criteria.

Examples
Assume the following variables were assigned values by statement DO SET:
Table 202 Values for SUM Function Examples

Variable Name Value

A1 2

A2 3

A3B 3

A1X 3

A2X 1

DB_CHKDBL@G0 1

DB_CHKDBL@G1 0

DB_CHKDBL@G2 1

DB_CHKDBL@G3 2

DB_CHKDBL 3
(not yet committed)

Table 203 SUM Function Examples

Function Returns value:

SUM('A*') 12

SUM('A?') 5

SUM('A?X') 4

SUM('DB_CHKDBL') 7

337
Control-M/Analyzer User Guide

TOLER: Functions
Determines if the percentage difference between two numbers is less than or equal to the specified
tolerance percentage.
Figure 166 TOLER Function Format

Syntax
TOLER(value1,value2,percent)

In this syntax
 value1 is a base value.
 value2 is a value to be compared with value1.
 pct is the maximum percentage tolerance.

General Information
The TOLER function calculates the percentage difference between value1 and value2 (assuming value1 is
100%). The result is compared to pct. If the calculated percentage is less than or equal to pct, TOLER
returns TRUE. If the calculated percentage is more than pct, TOLER returns FALSE.

338
Control-M/Analyzer User Guide

Examples
Table 204 TOLER Function Examples

Function Returns value:

TOLER(100,50,20) False

TOLER(100,80,20) True

TOLER(100,95,20) True

TOLER(100,100,0) True

TOLER(100,150,40) False

TOLER(150,100,40) True

TOLER(2000,2005,0.5) True

339
Control-M/Analyzer User Guide

TOLOWER: Functions
Converts a data string to lowercase characters.
Figure 167 TOLOWER Function Format

Syntax
TOLOWER(strng)

where strng is an Expression that evaluates to a data string. Mandatory.

General Information
The TOLOWER function returns a data string equivalent to the lowercase characters of strng. TOLOWER
works on data strings only.

Examples
Table 205 TOLOWER Function Examples

Function Returns value:

TOLOWER('RULE DEFINITION') 'rule definition'

TOLOWER(DB_CURRENT_EMP) 'barbara gordon'


where DB_CURRENT_EMP = ‘BARBARA GORDON’

340
Control-M/Analyzer User Guide

TOUPPER: Functions
Converts a data string to uppercase characters.
Figure 168 TOUPPER Function Format

Syntax
TOUPPER(strng)

where strng is an Expression that evaluates to a data string. Mandatory.

General Information
The TOUPPER function returns a data string equivalent to the uppercase characters of strng. TOUPPER
works on data strings only.

Examples
Table 206 TOUPPER Function Examples

Function Returns value:

TOUPPER('Rule Definition') 'RULE DEFINITION'

TOUPPER(DB_CURRENT_EMP) 'BARBARA GORDON'


where DB_CURRENT_EMP='Barbara Gordon'

341
Control-M/Analyzer User Guide

TRIMB: Functions
Removes (trims) trailing blanks from a data string.
Figure 169 TRIMB Function Format

Syntax
TRIMB(strng)

where strng is an Expression that evaluates to a data string. Mandatory.

General Information
The TRIMB function returns a data string equivalent to strng without trailing blanks. TRIMB works on data
strings only.

Examples
Table 207 TRIMB Function Examples

Function Returns value:

TRIMB('RULE DEFINITION ') 'RULE DEFINITION'

LENGTH(TRIMB('ANALYZER ')) 8

TRIMB('ABC DE ') 'ABC DE'

342
Control-M/Analyzer User Guide

TRIML: Functions
Removes (trims) leading blanks from a data string.
Figure 170 TRIML Function Format

Syntax
TRIML(strng)

where strng is an expression that evaluates to a data string. Mandatory.

General Information
The TRIML function returns a data string equivalent to strng without leading blanks. TRIML works on data
strings only.

Examples
Table 208 TRIML Function Examples

Function Returns value:

TRIML(' RULE DEFINITION') 'RULE DEFINITION'

LENGTH(TRIML(' ANALYZER')) 8

TRIML(' ABC DE') 'ABC DE'

343
Control-M/Analyzer User Guide

WORD: Functions
Returns the nth word in a text string. Delimiters can be specified as word separators.
Figure 171 WORD Function Format

Syntax
WORD(strng,delimiter,wordNum)

In this syntax
 strng is a data string (enclosed in quotes) or a variable with a value that is a string. Mandatory.
 delimiter is a set of characters, enclosed in quotes, each of which is used as a delimiter. Words are
the strings located from the start of strng to the first delimiter, or between two delimiters, or from the
last delimiter to the end of strng. Mandatory.
 wordNum is a number that represents the position of a word in strng. For example, 3 represents the
third word in the string. Mandatory.

General Information
The WORD function counts the words in the string. More than one delimiter, or type of delimiter, is
allowed. The function returns the word with a position in the string corresponding to wordNum (for
example, the first, fifth, or tenth word, if wordNum has the value of 1, 5, or 10, respectively).
If the specified delimiters do not exist, the entire string is considered one word.
If the specified word does not exist (for example, the fifth word was requested in a four word string), a
null string (a string of length zero) is returned and the SYSRC system variable is set to 4. The result can
be checked with the SYSNULL system variable (described in "SYSNULL" in Summary of System Variables
(on page 262)). The CTB295W warning message is issued.
Note: Leading blanks are ignored even if a blank is specified as the delimiter.

344
Control-M/Analyzer User Guide

Examples
Assume the following for the examples below:
Table 209 Values for WORD Function Examples

Variable Name Value

SENTENCE_CHECKED PLEASE COUNT THE WORDS

CHANGE_AROUND CHANGE,THIS,SENTENCE,AROUND

RANGE_OF_COLORS COLORS ARE RED,WHITE AND BLUE

Table 210 WORD Function Examples

Function Returns code:

WORD(SENTENCE_CHECKED,' ',2) COUNT

WORD(CHANGE_AROUND,',',4) AROUND

WORD(CHANGE_AROUND,' ',4) Null string

WORD(RANGE_OF_COLORS,', ',4) WHITE

345
Control-M/Analyzer User Guide

WORDNUM: Functions
Returns the number of words in a string.
Figure 172 WORDNUM Function Format

Syntax
WORDNUM(strng,delimiter)

In this syntax
 strng is a data string (enclosed in quotes) or a variable with a value that is a string. Mandatory.
 delimiter is a set of characters, enclosed in quotes, each of which is used as a delimiter. Words are
substrings located from the start of the string to the first delimiter, between two delimiters, and from
the last delimiter to the end of the string. Mandatory.

General Information
The WORDNUM function returns the number of words in the string. More than one delimiter, or type of
delimiter, is allowed.
If no specified delimiter exists, the entire sentence is considered one word.
Note: Leading blanks are ignored even if a blank is specified as the delimiter.

Examples
Assume the following for the examples below:

346
Control-M/Analyzer User Guide

Table 211 Values for WORDNUM Function Examples

Variable Name Value

SENTENCE_CHECKED PLEASE COUNT THE WORDS

CHANGE_AROUND CHANGE,THIS,SENTENCE,AROUND

Table 212 WORDNUM Function Examples

Function Returns value:

WORDNUM(SENTENCE_CHECKED,' ') 4

WORDNUM(CHANGE_AROUND,',') 4

WORDNUM(CHANGE_AROUND,' ') 1

347
5
5
Rule Definition
 Rule Definition (on page 349)
 EXECUTE Block Structure Overview (on page 351)
 Control-M/Analyzer Variables (on page 351)
 Rule Parameters – Summaries (on page 352)
 Parameter and Statement Descriptions (on page 357)
 ALWAYS: Data Identification Statement (on page 358)
 DESC: Basic Rule Parameter (on page 360)
 DO Statement: Automated Balancing Statement (on page 361)
 DO ADDSYM: Automated Balancing Statement (on page 364)
 DO BLOCK: Automated Balancing Statement (on page 368)
 DO CALLUSER: Automated Balancing Statement (on page 371)
 DO COMMIT: Automated Balancing Statement (on page 373)
 DO COND: Automated Balancing Statement (on page 378)
 DO EXIT: Automated Balancing Statement (on page 381)
 DO EXTRACT: Automated Balancing Statement (on page 382)
 DO GETMEM: Automated Balancing Statement (on page 397)
 DO GOTO: Automated Balancing Statement (on page 399)
 DO MAIL: Automated Balancing Statement (on page 402)
 DO PRINT: Automated Balancing Statement (on page 405)
 DO PUTMEM: Automated Balancing Statement (on page 412)
 DO REMARK: Automated Balancing Statement (on page 414)
 DO RULE: Automated Balancing Statement (on page 416)
 DO SET: Automated Balancing Statement (on page 418)
 DO SHOUT: Automated Balancing Statement (on page 421)
 DO SYSOUT: Automated Balancing Statement (on page 425)
 DO TERMINAT: Automated Balancing Statement (on page 428)
 EXECUTE: Data Selection Statement (on page 430)
 GROUP: Data Selection Statement (on page 433)
 IF: Data Selection Statement (on page 435)

348
Control-M/Analyzer User Guide

 ON Statement: Data Selection Statement (on page 438)


 ON CLASS: Data Selection Statement (on page 445)
 ON COMPARE: Data Selection Parameter (on page 448)
 ON DATA: Data Selection Statement (on page 458)
 ON DB2: Data Selection Statement (on page 461)
 ON DDNAME: Data Selection Statement (on page 465)
 ON DSN: Data Selection Statement (on page 467)
 ON FILE: Data Selection Statement (on page 469)

 ON PAGE: Data Selection Statement (on page 471)

 ON SYSDATA: Data Selection Statement (on page 474)


 ON SYSOUT: Data Selection Statement (on page 477)
 ON VSAM: Data Selection Statement (on page 480)
 OPTIONS: Basic Rule Parameter (on page 484)
 OWNER: Basic Rule Parameter (on page 485)
 UPDATED... BY: Basic Rule Parameter (on page 487)
 WHEN: Rule Definition Structure (on page 488)
 Rule Definition Using an Editor (on page 507)
 Rule Definition Structure (on page 508)
 Language Syntax (on page 510)
 Command Reference (on page 511)
 Rule Definition Process Examples (on page 521)

Rule Definition
The various selection criteria and instructions defined in each Control-M/Analyzer rule are called rule
parameters. Rule parameters are grouped together logically to form subunits called EXECUTE blocks.
General parameters and a series of EXECUTE blocks combine to form a rule definition.
This chapter is comprised of:
 an EXECUTE block structure overview
 a Control-M/Analyzer variables overview
 detailed descriptions of all parameters and their specific uses
BMC recommends that all Control-M/Analyzer users read the overview of the Rule Definition screen and
the description of the Online Scheduling facility in Online Facilities (on page 58) before reading this
section.

349
Control-M/Analyzer User Guide

Rule Definition parameters are defined through the Online facility using pre-formatted, "fill-in-the-blank"
screens. Rule definitions may also be created and modified using a standard editor and
Control-M/Analyzer Rule Definition language commands. This method is discussed in Rule Definition Using
an Editor (on page 507).
Figure 173 Control-M/Analyzer Rule Definition Screen
LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M43 GROUP ACCT_INV
UPDATED 04/04/00 - 15:25:54 BY M43
DESC REORDER INVENTORY ITEM CHR001 IF NECESSARY
OPTIONS
===========================================================================
/* INITIALIZATION OF THE MINIMUM AMOUNT REQUIRED ON-HAND FOR
/* INVENTORY ITEM CHR001.
EXECUTE SETUP UPON C
ON DATA
ALWAYS
DO SET = MIN_CHR001=100 C
===========================================================================
/* DETERMINE CURRENT ON-HAND QUANTITY OF INVENTORY ITEM CHR001 BY
/* EXTRACTING THIS VALUE FROM SYSOUT DDNAME INVENTRY.
EXECUTE CHECK UPON C
ON SYSOUT PROCST PGMST DDNAME INVENTRY JOBNM
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = CHR001
PLEASE FILL IN RULE DEFINITION. 09.25.30

All rule definitions are stored as members in standard user libraries. One member must exist for each rule,
and the member name is identical to the rule name. Maintenance within the library and management of
the operating instructions are performed using the Online Rule Definition facility or a standard editor.
When defining rule definitions using the Online facility, definitions can be modified by entering the
Control-M/Analyzer Edit Environment. ISPF-like line commands may be specified to copy, delete, insert,
move, and repeat lines of the definition. For additional information and examples refer to A Editing Rule
Definitions in the IOA Edit Environment (on page 660).
There are four types of rule parameters:
 Basic Rule parameters
 Data Selection statements (ON statements)
 Data Identification statements (WHEN, ALWAYS, and IF statements)
 Automated Balancing statements (DO statements)
This chapter first describes the EXECUTE block structure, followed by an overview of Control-M/Analyzer
variables, and then presents a quick summary of the rule parameters in each of the four groups listed
above.
The summary is followed by detailed descriptions of each parameter and statement in alphabetical order.
Subparameters are presented in the order of their fields on the screen.
The detailed descriptions of the parameters are followed by an overview and quick reference guide for
creating and modifying rules using a standard editor. The guide contains the syntax and options of each
parameter. Examples are also provided.

350
Control-M/Analyzer User Guide

EXECUTE Block Structure Overview


Each Control-M/Analyzer rule is composed of a series of EXECUTE blocks. Each EXECUTE block specifies
the data source to balance, specific data to search for, and processing actions to take.
Every EXECUTE block must contain only one ON statement, one or more WHEN blocks (or IF/ALWAYS
blocks when ON DATA is specified), and a series of Automated Balancing statements (DO statements).
The basic structure of an EXECUTE block is:
Figure 174 Basic Structure of an EXECUTE Block
EXECUTE <block name> UPON <execution criteria>
ON <data source>
WHEN <criteria>
<DO statement>
<DO statement>
WHEN <criteria>
<DO statement>
<DO statement>

A rule can contain an unlimited number of EXECUTE blocks. The EXECUTE blocks are processed
sequentially within a rule, unless specified otherwise by DO GOTO or DO BLOCK statements.
For additional information about EXECUTE blocks, see EXECUTE Block Structure Overview (on page 37).

Control-M/Analyzer Variables
Control-M/Analyzer provides Database, AutoEdit, Local, and System types of variables for storing values.
For a comprehensive description of all variable types, see Chapter 3, "Control-M/Analyzer Variables".
 Control-M/Analyzer Database variables are unique to Control-M/Analyzer. Control-M/Analyzer rules
can initialize variables and store these values in the Database for future use.
 AutoEdit variables are stored in AutoEdit members and can be subsequently used in other rules or by
other INCONTROL products.
 Local variables can be used throughout the execution of a rule but are not available after rule
termination.
 System variables store values that are automatically defined by the system. These variables can be
used throughout the execution of a rule but are not available after rule termination.
The DO EXTRACT statement extracts data from a sysout or file and stores the data in a variable.
The DO SET statement sets the value of a variable in the form of a Control-M/Analyzer expression.
IF statements and the UPON parameter can contain Control-M/Analyzer variables in expression format.
For additional information about expressions, see Expressions and Functions (on page 269).

351
Control-M/Analyzer User Guide

Rule Parameters – Summaries


Comprehensive descriptions of Control-M/Analyzer Rule Definition parameters are provided later in this
chapter. They are arranged alphabetically. Subparameters are listed according to the order of the fields
on the screen.
Each parameter begins on a new page, headed by its name in uppercase letters. This is followed by a
brief explanation of the purpose of the parameter.
The format required for defining the parameter is presented next. An extract of the Rule Definition screen
illustrates where and how the parameter is specified on the screen.
General Information gives a detailed explanation of the parameter and its uses.
A number of practical examples are provided to illustrate the implementation of each parameter.
Note: Avoid using Control-M/Analyzer reserved words in rule parameter specifications. For a complete list
of reserved words, see B Reserved Words (on page 673).

Basic Rule Parameters


Basic Rule parameters provide basic information about the rule.
Table 213 Basic Rule Parameters

Parameter Description

OWNER ID of the owner of the rule.

GROUP Name of a user-defined group, such as ACCOUNTING or


INVENTORY).

UPDATED ... BY Date of last update of the rule and last user to update the rule.

DESC Free text description of the rule.

OPTIONS For future use.

352
Control-M/Analyzer User Guide

Data Selection Statements


Data Selection statements specify the data source to be balanced by Control-M/Analyzer. These
statements also specify conditional criteria and branching instructions that control which EXECUTE blocks
within a rule are processed.
Table 214 Data Selection Statements

Statement Description

EXECUTE Statement Provides a name for the EXECUTE block and determines whether
the block is executed based on conditional UPON criteria.

ON Statement Specifies the source of data that the rule attempts to balance.

ON CLASS Job outputs of a specified class.

ON COMPARE Datasets that are input for the reconciliation process.

ON DB2 Data from DB2 tables.

ON DDNAME Datasets referenced by a DD statement in the current step.

ON DSN For Control-D and Control-V users only: Compressed Dataset Access
Method (CDAM) files.

ON FILE Sequential or partitioned dataset.

ON PAGE For Control-D and Control-V users only: Pages passed to


Control-M/Analyzer when report output is decollated.

ON SYSDATA For Control-M and Control-M/Restart users only: The three job
sysout datasets, referred to as SYSDATA,a passed to
Control-M/Analyzer from Control-M when Control-M analyzes a job
run.

ON SYSOUT Outputs referenced by PGMNAME/PROCNAME parameters on a


specified DD name statement.

ON VSAM VSAM file records. Identified by user-specified keys.

ON DATA Control-M/Analyzer variables.

An EXECUTE block is comprised of one Data Selection statement (ON block), one or more Data
Identification statements (WHEN, ALWAYS, or IF), and a series of DO statements for each Data
Identification statement.
Different Data Identification statements (WHEN, ALWAYS, and IF) are displayed based on which ON
statement is used.

353
Control-M/Analyzer User Guide

Figure 175 Structure of an EXECUTE Block

354
Control-M/Analyzer User Guide

Data Identification Statements


Data Identification statements specify the actual criteria (character strings and values) that
Control-M/Analyzer should examine within the data source specified by a Data Selection ON statement.
Table 215 Data Identification Statements

Statement Description

WHEN Specifies conditional criteria required to conduct a data search. If


the criteria are met, subsequent DO statements are executed.
Available in all EXECUTE blocks except those containing an ON
DATA statement.

ALWAYS Specifies unconditional execution of DO statements in an EXECUTE


block following an ON DATA statement.

IF Provides Boolean logic capabilities in an EXECUTE block containing


an ON DATA statement. If the criteria are met, subsequent DO
statements are executed. Statement ELSE can optionally be
specified with its own DO statements that are executed if the
criteria are not met.

Automated Balancing Statements


Automated Balancing statements (DO statements) specify actions to be performed by Control-M/Analyzer.
These actions are performed only after Data Selection and Identification criteria are processed.
To specify Automated Balancing statements, type the statement name (for example, BLOCK, COND, SET)
next to the DO on the Rule Definition screen and press Enter. Different parameters are displayed on the
screen depending on which DO statement was specified.
Note: It is usually not necessary to enter the full DO statement name. The shortest unique abbreviation of
the statement is sufficient.

355
Control-M/Analyzer User Guide

Table 216 Automated Balancing Statements

Statement Description

DO ADDSYM Adds an AutoEdit variable to an existing or new AutoEdit member.

DO BLOCK Executes a different EXECUTE block within the current rule.

DO CALLUSER Executes a user routine from the current rule.

DO COMMIT Controls the method that Database variables are written to the
Control-M/Analyzer Database.

DO COND Specifies prerequisite conditions to be added or deleted.

DO EXIT Terminates execution of the current block.

DO EXTRACT Assigns a value to a Control-M/Analyzer Database, AutoEdit, or


Local variable based on text extracted from the data source.

DO GETMEM Reads (accesses) an AutoEdit member, enabling the use of its


AutoEdit variables for AutoEdit processing.

DO GOTO Provides "GO TO" logic by executing the IF/ALWAYS block that
begins with the specified LABEL.

DO MAIL Send an e-mail to the specified recipients.

DO PRINT Prints the specified string to the Control-M/Analyzer Rule Activity


report.

DO PUTMEM Writes an AutoEdit member back to a specified library.

DO REMARK Specifies a remark to be logged as a Control-M/Analyzer invocation


entry in the Rule Activity display.

DO RULE Executes a different rule from within the current rule.

DO SET Assigns a value to a Control-M/Analyzer Database, AutoEdit, or


Local variable.

DO SHOUT Sends a message to a specified destination.

DO SYSOUT Specifies how job output should be handled.

DO TERMINAT Terminates the rule and specifies the result of the data balancing
effort (for example, OK, TOLER, NOTOK, or ABEND).

356
Control-M/Analyzer User Guide

Parameter and Statement Descriptions


The following pages contain detailed descriptions of all parameters available in the Rule Definition screen.
Parameters are arranged in alphabetical order. Within each parameter, subparameters are arranged
according to the order of the fields on the screen.
Each parameter begins on a new page, including:
 A brief explanation of the purpose of the parameter.
 The format required for defining the parameter within an extract of the Control-M/Analyzer screen.
 General information explaining the parameter and its usage.
 Where applicable, some practical examples illustrating implementation of the parameter.
For more information on the Rule Definition facility, see Online Facilities (on page 58).

357
Control-M/Analyzer User Guide

ALWAYS: Data Identification Statement


Specifies unconditional execution of associated DO statements.
Figure 176 ALWAYS Statement Format

Optional. When ON DATA is specified and Enter is pressed, the ALWAYS statement can be specified in
the field that is opened on the screen. When ALWAYS (or its abbreviation A) is specified and Enter is
pressed, the following fields are displayed:
Table 217 ALWAYS Statement Fields

Field Description

LABEL Name associated with the subsequent DO statements. LABEL can


have a maximum of 8 characters. Label names must be unique
within a rule definition.

DO Specification of Automated Balancing statements. For summary


information about each DO statement, see Automated Balancing
Statements (on page 355).

General Information
Available only when ON DATA is specified.
The DO statements after the ALWAYS statement are always executed.
The LABEL parameter is used as a reference point for flow processing (branching). LABEL is used in
conjunction with the DO GOTO statement. When specified, DO GOTO passes processing control to the
matching LABEL. See DO GOTO in this chapter for additional information.

358
Control-M/Analyzer User Guide

Example
Statement ALWAYS is commonly used for initialization and preparatory actions that should be performed
before processing begins. In this example, statement ALWAYS:
 Appears in the first EXECUTE block of the rule definition.
 Initializes counters that are used later in this rule definition.
Prepares header lines for the report that the rule definition produces.
Figure 177 ALWAYS Statement Example
LIBRARY : CTB.PROD.RULES RULE : RULEMP
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M18B GROUP ADMIN
UPDATED 04/04/00 - 15:30:05 BY M18B
DESC CHECK EMPLOYEES REPORT FOR BALANCING
OPTIONS
===========================================================================
EXECUTE PREPARE UPON C
ON DATA
LABEL: INIT
ALWAYS
DO SET = CNTR=0 C
DO SET = ERR=0 C
DO PRINT = UNREASONABLE SICK/VACATION DAYS F C
DO PRINT = ================================= F C
DO PRINT = +--+---------------+------+-----+ F C
DO PRINT = | | NAME | SICK | VAC | F C
DO PRINT = +--+---------------+------+-----+ F C
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE INPUT UPON C
PLEASE FILL IN RULE DEFINITION. 18.31.58

359
Control-M/Analyzer User Guide

DESC: Basic Rule Parameter


Describes the rule in free text.
Figure 178 DESC Parameter Format

Optional. DESC specifies description text of 1 through 50 characters.

General Information
A rule description can be specified in any language. It is used as an internal help facility, assisting the
user in documenting the rule under Control-M/Analyzer.

360
Control-M/Analyzer User Guide

Examples
Figure 179 DESC Parameter Format
LIBRARY : CTB.PROD.RULES RULE : CHECKCUR
COMMAND ===> SCROLL===> CRSR
------------------------------------------------------------------------------+
OWNER M55 GROUP CURRENCY
UPDATED 04/04/00 - 09:18:35 BY M55A
DESC CHECK BALANCING OF BANK'S FOREIGN CURRENCY INVESTMENTS
OPTIONS
===========================================================================
EXECUTE CHECK UPON C
ON SYSOUT PROCST PGMST DDNAME REPORT JOBNM
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 020 - 030 COL 001 - 132 STOP AND/OR
STRING = NOT BALANCED
DO SHOUT TO OPER URGENCY R
= FOREIGN CURRENCY REPORT NOT BALANCED !!!
DO TERMINAT = NOTOK COD 1001
===========================================================================
EXECUTE UPON C
ON
====== >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 09.25.35

DO Statement: Automated Balancing Statement


Specifies an action to take following an ALWAYS statement or if criteria of a WHEN, IF or ELSE are
satisfied.
Figure 180 DO Statement Format

Optional. Valid DO actions:


Table 218 DO Statement Actions

Action Description

DO ADDSYM Adds an AutoEdit variable to an AutoEdit member.

361
Control-M/Analyzer User Guide

Action Description

DO BLOCK Executes a different EXECUTE block within the current rule.

DO CALLUSER Executes a user routine from the current rule.

DO COMMIT Controls the method used to write Database variables to the


Control-M/Analyzer Database.

DO COND Specifies prerequisite conditions to be added or deleted.

DO EXIT Terminates execution of the current block.

DO EXTRACT Assigns a value to a Control-M/Analyzer Database, AutoEdit, or


Local variable based on text extracted from the data source.

DO GETMEM Reads an AutoEdit member, from an AutoEdit member.

DO GOTO Provides "go to" logic by executing the IF/ALWAYS block that begins
with the specified LABEL.

DO MAIL Sends an e-mail to the specified recipients.

DO PRINT Prints the specified string to the Control-M/Analyzer Rule Activity


report.

DO PUTMEM Writes an AutoEdit member back to a specified library.

DO REMARK Specifies a remark to be logged as a Control-M/Analyzer invocation


entry in the Rule Activity display.

DO RULE Executes a different rule from within the current rule.

DO SET Assigns a value to a Control-M/Analyzer Database, AutoEdit, or


Local variable.

DO SHOUT Sends a message to specified destinations.

DO SYSOUT Specifies how job output should be handled.

DO TERMINAT Terminates the rule and specifies the result of the data balancing
effort, such as OK, TOLER, NOTOK, or ABEND.

General Information
DO statements are associated with a preceding ALWAYS, WHEN, IF or ELSE statement (described in
Command Reference (on page 511)). The implied relationship is:

362
Control-M/Analyzer User Guide

Table 219 Preceding Statements Associated with DO Statements

Statement Description

ALWAYS Perform all actions specified in the DO statements.

IF, ELSE If IF or ELSE statement criteria are satisfied, perform all actions
specified in the appropriate DO statements.

WHEN If the WHEN string is found, perform all actions specified in the DO
statements.

Whenever a DO statement is specified, an empty DO statement is added after it.


To delete unwanted DO statements, either delete the DO action keyword and press Enter or specify the
appropriate line editing commands in the IOA Edit Environment (described in A Editing Rule Definitions
in the IOA Edit Environment (on page 660)).

363
Control-M/Analyzer User Guide

DO ADDSYM: Automated Balancing Statement


Adds an AutoEdit variable to an existing AutoEdit member that has been read (through statement DO
GETMEM) or to a new AutoEdit member that will be created (through statement DO PUTMEM).
Figure 181 DO ADDSYM Statement Format

Optional. Type the word ADDSYM (or its abbreviation A) next to the DO in the Rule Definition screen.
When Enter is pressed, the = prompt and the following fields are displayed:
Table 220 ADDSYM Statement Fields

Field Description

variable Name of the AutoEdit variable to add (46 character maximum).


Must begin with prefix %%. Mandatory.

MEM Name of an existing or new AutoEdit member (8 character


maximum) that contains the new AutoEdit variable.

LIBSYM Name of the library (44 character maximum) that contains (or will
contain) the AutoEdit member.

364
Control-M/Analyzer User Guide

General Information
AutoEdit variables can be used to pass information between Control-M/Analyzer rules and between
Control-M/Analyzer and other INCONTROL products (for example, Control-M, Control-D, Control-O).
The following statements access AutoEdit members:
 DO GETMEM enables subsequent actions of the rule to access (through AutoEdit statements or DO
SET statements) AutoEdit variables contained in the specified AutoEdit member.
 DO ADDSYM adds an AutoEdit variable to an AutoEdit member.
 DO PUTMEM writes the AutoEdit member back to its library for future use.
Using DO ADDSYM, a new AutoEdit variable is associated with (added to) the specified AutoEdit member.
The initial value of the variable is null.
An AutoEdit variable can be referred to by a rule only if:
 The variable has been read previously by statement DO GETMEM, or
 Statement DO ADDSYM has been performed for this variable.
All AutoEdit variables must be associated with an AutoEdit member (by one of the two methods listed
above) before the variable can be accessed.
If a rule refers to an AutoEdit variable through statement DO ADDSYM, the variable is created even if the
associated AutoEdit member MEM was not read by statement DO GETMEM. However, statement DO
PUTMEM fails and a runtime error occurs if the AutoEdit member specified in the MEM parameter exists in
the library specified in LIBSYM and that member was not previously read by statement DO GETMEM.
Control-M/Analyzer AutoEdit variables and Local variables (preceded by the %% operator) can be
embedded in the LIBSYM and MEM parameters of statement DO ADDSYM. The variables are resolved
(replaced) at the time of rule execution. For additional information on AutoEdit processing, see
Control-M/Analyzer Variables (on page 222).
For additional information, see DO GETMEM: Automated Balancing Statement (on page 397), and DO
PUTMEM: Automated Balancing Statement (on page 412).

Example
The following example uses a central bank report that lists interest rates at month-end. The last banking
day of each month is also provided in the following format:

365
Control-M/Analyzer User Guide

Figure 182 Begin DO ADDSYM Example


DATE 01/01/00 TIME 23:50 PAGE 000001

I N T E R E S T R A T E S A T M O N T H - E N D YEAR: 2000

LAST DAY PROJECTED


MONTH OF MONTH INTEREST RATE
+-----------------------------------------------------------------+
| 01 JANUARY | 31 | 5.25 % |
| 02 FEBRUARY | 29 | 5.25 % |
| 03 MARCH | 31 | 5.26 % |
| 04 APRIL | 30 | 5.26 % |
| 05 MAY | 31 | 5.27 % |
| 06 JUNE | 30 | 5.28 % |
| 07 JULY | 31 | 5.24 % |
| 08 AUGUST | 31 | 5.24 % |
| 09 SEPTEMBER | 30 | 5.24 % |
| 10 OCTOBER | 31 | 5.25 % |
| 11 NOVEMBER | 30 | 5.26 % |
| 12 DECEMBER | 31 | 5.27 % |
+-----------------------------------------------------------------+
---+----1----+----2----+----3----+----4----+----5----+----6----+---

The Control-M/Analyzer rule updates an AutoEdit member that contains AutoEdit variables in the following
format:
Figure 183 AutoEdit Member Updated by DO ADDSYM Statement Example
%%LAST_BANKING_DAY_0001=000131
%%LAST_BANKING_DAY_0002=000229
%%LAST_BANKING_DAY_0003=000331
%%LAST_BANKING_DAY_0004=000428
%%LAST_BANKING_DAY_0005=000531
%%LAST_BANKING_DAY_0006=000630
%%LAST_BANKING_DAY_0007=000731
%%LAST_BANKING_DAY_0008=000831
%%LAST_BANKING_DAY_0009=000929
%%LAST_BANKING_DAY_0010=001031
%%LAST_BANKING_DAY_0011=001130
%%LAST_BANKING_DAY_0012=001229

The rule adds the new AutoEdit variables to the existing AutoEdit member LSTBNKDY using statement DO
ADDSYM.
First, the new AutoEdit variable is added using statement DO ADDSYM. Afterward, this variable is set
using statement DO EXTRACT.

366
Control-M/Analyzer User Guide

Figure 184 End DO ADDSYM Example


LIBRARY : CTB.PROD.RULES RULE :BANKDAYS
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE INIT UPON C
ON DATA
ALWAYS
DO GETMEM = LSTBNKDY
LIBSYM CTB.PROD.SYMBOLS
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE GETDATES UPON C
ON SYSOUT PROCST PGMST STEP01 DDNAME BANKDAYS JOBNM
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 001 - 060 COL 001 - 132 STOP AND/OR
STRING = |
DO EXTRACT = MONTH
LEVEL LINE +000 COL +003 - +005 PROCESS TYP
DO ADDSYM = %%LAST_BANKING_DAY_%%MONTH MEM LSTBNKDY
LIBSYM CTB.PROD.SYMBOLS
DO EXTRACT = %%LAST_BANKING_DAY_%%MONTH
LEVEL 0 LINE +000 COL +041 - +045 PROCESS TYP
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE FINISH UPON C
ON DATA
ALWAYS
DO PUTMEM = LSTBNKDY
LIBSYM CTB.PROD.SYMBOLS
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 17.07.34

367
Control-M/Analyzer User Guide

DO BLOCK: Automated Balancing Statement


Processes another EXECUTE block in the current rule (if its UPON criteria are met).
Figure 185 DO BLOCK Statement Format

Optional. Type the word BLOCK (or its abbreviation B) next to the DO in the Rule Definition screen. When
Enter is pressed, the = prompt and the following fields are displayed:
Table 221 DO BLOCK Statement Fields

Field Description

name Name of the block to process. The block name can have a maximum
of 8 characters. The name of the block should match the block
name specified in an EXECUTE statement. Mandatory.

ARG Optional input and output arguments to be passed to the block. If


specified, arguments must be predefined Local or Database
variables, separated by commas. A maximum of 50 arguments can
be specified.

Note: Database variables can be embedded in the ARG parameter only if they have not yet been
committed. After a Database variable is committed, it cannot be specified in the ARG parameter.
When set to Y (Yes), the C (Continue?) field provides additional space for specifying arguments. A
maximum of 10 lines can be opened. Specifying N (No) in the C (Continue?) field closes the ARG field.

General Information
The DO BLOCK statement provides non-sequential program execution within a rule. When a DO BLOCK
statement is encountered during rule processing, Control-M/Analyzer searches for the corresponding
EXECUTE block name in the rule definition. When found, the statements following the specified EXECUTE
block name are executed. When the specified EXECUTE block finishes processing, processing flow
continues sequentially from the point after the DO BLOCK statement.

368
Control-M/Analyzer User Guide

As explained in the ARG parameter, the rule may pass variables as input to the called block. These
variables are called block arguments. Block arguments must be Local or Database variables that have
already been initialized. The called block may change the values of these arguments, causing the new
values to be accessed by the rule.
The called block refers to these arguments by System variables BARGnn, where nn is a number from 1 to
the actual number of passed arguments.
Control-M/Analyzer AutoEdit variables plus Local and Database variables can be embedded in the
arguments. The variables are resolved (replaced) at time of rule execution. For additional information on
AutoEdit processing, see Control-M/Analyzer Variables (on page 222), and in particular Passing Variables
to Blocks, Rules and User Routines (on page 224).

369
Control-M/Analyzer User Guide

Example
EXECUTE block INPUT extracts personnel information from a report. Statement DO BLOCK calls EXECUTE
block CHECK to process this information.
The information extracted from the report is passed as arguments to EXECUTE block CHECK.
EXECUTE block CHECK is located after EXECUTE block FIN that terminates the rule. Block CHECK can only
be activated by statement DO BLOCK in block INPUT.
Figure 186 DO BLOCK Statement Example
LIBRARY : CTB.PROD.RULES RULE : RULEMP
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE INPUT UPON C
ON FILE FILENAME CTB.PROD.EMPREP
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 001 - 060 COL 013 - 014 STOP AND/OR
STRING = #
DO EXTRACT = NAME
LEVEL 0 LINE +000 COL -002 - +013 PROCESS TYP
DO EXTRACT = SICK
LEVEL 0 LINE +000 COL +087 - +088 PROCESS TYP
DO EXTRACT = VAC
LEVEL 0 LINE +000 COL +093 - +094 PROCESS TYP
DO BLOCK = CHECK ARG NAME,SICK,VAC C
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE FIN UPON C
ON DATA
ALWAYS
DO PRINT = +--+---------------+------+-----+ F C
DO PRINT = CHECKED %%CNTR USERS, FOUND %%ERR ERRORS F C
DO REMARK = CHECKED %%CNTR USERS, FOUND %%ERR ERRORS
DO
IF ERR > 5 C
DO TERMINAT = NOTOK COD 2000
DO
===========================================================================
EXECUTE CHECK UPON C
ON DATA
ALWAYS
DO SET = CNTR=CNTR+1 C
DO
IF BARG02 > 90 OR BARG03 > 30 C
DO PRINT = | |%%BARG01| %%BARG02 | %%BARG03 | F C
DO SET = ERR=ERR+1 C
DO
(ENTER "ALWAYS", "IF" OR "ELSE")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

370
Control-M/Analyzer User Guide

DO CALLUSER: Automated Balancing Statement


Calls a user routine.
Figure 187 DO CALLUSER Statement Format

Optional. Type the word CALLUSER (or its abbreviation CA) next to the DO in the Rule Definition screen.
When Enter is pressed, the = prompt and the following fields are displayed:
Table 222 DO CALLUSER Statement Fields

Field Description

name Name of the user routine to process. This name can have a
maximum of 8 characters. Mandatory.
Program CTBRECL is the user routine that invokes the Reconciliation
facility.

ARG Input and output arguments to be passed to the block. If specified,


arguments must be predefined Local or Database variables,
separated by commas. A maximum of 50 arguments can be
specified. Optional.

Note: Database variables can be embedded in the ARG parameter only if they have not yet been
committed. After a Database variable is committed, it cannot be specified in the ARG parameter.
When set to Y (Yes), the C (Continue?) field provides space for specifying additional variables. A
maximum of 10 lines can be opened. Specifying N (No) in the C (Continue?) field closes the following
preexisting line.

General Information
The user routine does not have to exist before defining the rule. It must exist prior to rule execution. For
additional information on writing and using user written routines, see A Editing Rule Definitions in the
IOA Edit Environment (on page 660).

371
Control-M/Analyzer User Guide

When Control-M/Analyzer encounters statement DO CALLUSER, the user routine is processed. After the
user routine is processed, processing flow returns to the point in the rule after DO CALLUSER.
If no matching user routine exists, a runtime error occurs.
The return code of the user routine is placed in System variable SYSRC.
AutoEdit variables, plus Local and Database variables prefixed by the %% operator, can be embedded in
the ARG parameter of statement DO CALLUSER. These variables are resolved (replaced) at time of rule
execution. For additional information on AutoEdit processing, see Control-M/Analyzer Variables (on page
222), and in particular Passing Variables to Blocks, Rules and User Routines (on page 224).
For a complete explanation of the Reconciliation facility and how to use it,see Reconciliation Facility (on
page 600).
See member CTBCALLU in the IOA.SAMPLE library for more information about the structure of user
routines that can be called by statement DO CALLUSER.

Example
If the string SEVERE ERROR FOUND, RC= is issued by a program that updates an accounting database,
user routine RESTORDB is called by statement DO CALLUSER. This user routine restores the accounting
database to its previous state.
The return code from the update program is passed as an argument to the user routine.
EXECUTE block FINISH is executed only if the return code from the user routine is greater than zero.
Figure 188 DO CALLUSER Statement Example
LIBRARY : CTB.PROD.RULES RULE : ACCTUPDT
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE CHECK UPON C
ON SYSOUT PROCST PGMST STEP03 DDNAME REPORT JOBNM
MODE PG LINECT 0060
DATASTAMP
WHEN LINE 001 - 060 COL 001 - 132 STOP AND/OR
STRING = SEVERE ERROR FOUND, RC=
DO EXTRACT = RETCODE
LEVEL 0 LINE +000 COL +023 - +026 PROCESS TYP
DO CALLUSER = RESTORDB ARG RETCODE C
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE FINISH UPON SYSURC>0 C
ON DATA
ALWAYS
DO SHOUT TO OPER2 URGENCY R
= SEVERE PROBLEMS WITH ACCOUNTS DATABASE !! CALL ACC.DEPT NOW
DO
PLEASE FILL IN RULE DEFINITION. 14.06.28

372
Control-M/Analyzer User Guide

DO COMMIT: Automated Balancing Statement


Determines which Database variables to write (commit) to the Control-M/Analyzer Database and when to
commit them.
Figure 189 DO COMMIT Statement Format

Optional. Type the word COMMIT (or its abbreviation COM) next to the DO in the Rule Definition screen.
Press Enter and the = prompt and the following fields are displayed:

373
Control-M/Analyzer User Guide

Table 223 DO COMMIT Subparameters

Subparameter Description

method Mandatory. Valid DO COMMIT methods are:


 ALL – Marks for commitment all Database variables modified
using DO SET or DO EXTRACT. Commitment occurs at rule
termination.
 NONE – Unmarks all Database variables previously marked for
commitment. Database variables that are subsequently set are
marked for commitment and committed at rule termination.
 EXCLUDE – Unmarks specific Database variables previously
marked for commitment. The list of variables to unmark is
supplied by the VAR parameter. If any of these Database
variables are subsequently set, they are re-marked for
commitment and committed at rule termination.
 NOW – Forces immediate commitment of specific modified
Database variables. The list of variables to commit is supplied
by the values in the VAR parameter.
 DELETE – Forces immediate deletion of previously set Database
variables from the Runtime Environment of the rule (as if these
variables were never set).
 INCLUDE – Marks for commitment specific modified Database
variables. The list of variables to be marked is supplied by the
values in the VAR parameter. Commitment occurs at rule
termination.

VAR When using the INCLUDE, EXCLUDE or NOW method, the VAR
parameter must specify the appropriate variable names separated
by commas. When using the ALL, NONE or DELETE method, the
VAR field should be left blank.

C (Continue) Provides space for specifying additional variable names. A maximum


of 10 lines can be opened. Valid values are:
 Y (Yes) – Space is required for additional variable names. Opens
an additional line for further variable names to be entered.
 N (No) – No additional space is required. Closes any pre-existing
following line.

374
Control-M/Analyzer User Guide

General Information
By default, Database variables modified by a rule (using statement DO SET or DO EXTRACT) are not
immediately written to (stored in) the Control-M/Analyzer Database. Instead, Database variables are
committed at rule termination if the rule does not abend.
 If the rule was called by a job step, commitment occurs when the rule terminates.
 If the rule was called by another rule through statement DO RULE, commitment occurs when the
called rule terminates.
DO COMMIT statements specified by a rule may override this default and force immediate commitment of
Database variables.
Note: Subsequent settings of a variable (before commitment occurs) change the current value of the
variable. Only the current value of the variable is written to the Database.
The DO COMMIT statement enables a rule to:
 Mark or unmark all modified Database variables for commitment.
 Selectively mark or unmark specific Database variables for commitment.
 Force immediate commitment of specific Database variables.
 Delete specific Database variables from the memory of the rule as if these variables were never set.
The DO COMMIT options described above are useful when various rule results and decisions affect how
variables should be committed.
If a rule ends OK, all Database variables are committed. However, if the rule ends NOTOK, it may be
preferred that no variables be committed. In this latter case, DO COMMIT=NONE could be specified
before rule termination to achieve the desired effect.
Instead of issuing a "global" COMMIT (for example, the default COMMIT method), it is possible to commit
certain variables, but not others. This can be achieved by using the DO COMMIT options INCLUDE or
EXCLUDE and specifying the desired variables in the VAR parameter.
The NOW option forces immediate commitment of specified variables. This option enables the creation of
several generations of the same variable during the same rule execution.
The DELETE option reverses variable settings and modifications (provided that the variable was not
already committed). The result is that the variable is undefined as if it had not been previously set or
modified.
Note: The DELETE option frees (unlocks) the Database variable so it can be accessed by other rules
executing concurrently. The EXCLUDE option unmarks the variable for commitment but does not free the
variable until rule termination.
Control-M/Analyzer AutoEdit variables and Local variables (preceded by the %% operator) can be
embedded in the VAR parameter. These variables are resolved (replaced) at time of rule execution. For
additional information on AutoEdit processing, see Control-M/Analyzer Variables (on page 222).
For additional information on committing Database variables, see Committing Database Variables (on
page 233).

375
Control-M/Analyzer User Guide

Examples
Example 1
By default, if the rule terminates OK, all Database variables are committed. However, if the rule ends
NOTOK, statement DO COMMIT=NONE is performed. The variables are not committed because the values
extracted from the report in the previous EXECUTE block may be wrong.
Figure 190 DO COMMIT Statement – Example 1
LIBRARY : CTB.PROD.RULES RULE : CHKCURR
COMMAND ===> SCROLL===> CRSR
+------------------------------------------------------------------------------+
===========================================================================
EXECUTE INPUT UPON C
ON SYSOUT PROCST PGMST STEP00 DDNAME SYSUT2 JOBNM
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 006 - 060 COL 008 - 009 STOP AND/OR
STRING = /
DO EXTRACT = DB_CURRENCY.SUM
LEVEL 0 LINE +000 COL +084 - +094 PROCESS TYP
DO
WHEN LINE 006 - 060 COL 003 - 013 STOP AND/OR
STRING = TOTALS
DO EXTRACT = DB_CURRENCY.TOTAL
LEVEL 0 LINE +000 COL +001 - +006 PROCESS TYP
DO EXTRACT = DB_CURRENCY.AVERAGE
LEVEL 0 LINE +000 COL +020 - +026 PROCESS TYP
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE COMMIT UPON C
ON DATA
IF DB_CURRENCY.SUM > 50000.00 C
DO SHOUT TO U-M18 URGENCY R
= PLEASE CHECK CURRENCY FILE; PROBLEMS WITH SUM
DO REMARK = SUM IS OVER 50000
DO COMMIT = NONE VAR C
DO TERMINAT = NOTOK COD 0055
DO
ELSE
DO REMARK = SUM IS NOT OVER 50000
DO TERMINAT = OK COD 0000
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
PLEASE FILL IN RULE DEFINITION. 14.36.10

Example 2
Total values for the last six months are extracted from a report. Each of these values is saved as a
separate generation of the Database variable DB_CURRENCY.TOTAL. This result is achieved by specifying
statement DO COMMIT=NOW after each appearance of this variable in the report.

376
Control-M/Analyzer User Guide

Figure 191 DO COMMIT Statement – Example 2


LIBRARY : CTB.PROD.RULES RULE : CURRDB
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M18B GROUP CURRENCY
UPDATED 04/04/00 - 15:30:05 BY M18B
DESC EXTRACT VALUES FROM A REPORT AND UPDATE DATABASE
OPTIONS
===========================================================================
EXECUTE INPUT UPON C
ON SYSOUT PROCST PGMST STEP2 DDNAME TOTALREP JOBNM
MODE PG LINECT 0060
DATASTAMP
WHEN LINE 006 - 060 COL 008 - 009 STOP AND/OR
STRING = TOTALS FOR THIS MONTH:
DO EXTRACT = DB_CURRENCY.TOTAL
LEVEL 0 LINE +000 COL +084 - +094 PROCESS TYP
DO COMMIT = NOW VAR DB_CURRENCY.TOTAL C
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE UPON C
ON
PLEASE FILL IN RULE DEFINITION. 14.45.05

377
Control-M/Analyzer User Guide

DO COND: Automated Balancing Statement


Specifies prerequisite conditions to be added to and/or deleted from the IOA Conditions file.
Figure 192 DO COND Statement Format

Optional. Type the word COND (or its abbreviation CON) next to the DO on the Rule Definition screen.
When Enter is pressed, Control-M/Analyzer creates an area for the prerequisite condition to be entered.
Table 224 DO COND Statement Fields

Field Description

condition User supplied, descriptive name of 1-20 characters. Only trailing


blanks are allowed. Long condition names are not supported.
Mandatory.
Note: A condition name should not begin with the "|" symbol and
should not contain parentheses ( ) because these characters are
used in defining Boolean logic for conditions.

378
Control-M/Analyzer User Guide

Field Description

dateref Four character date reference. Mandatory. Valid values are:


 STAT – Static. Indicates that the condition (for
example, PRINTER-READY) is not date dependent.
 ODAT – Control-M/Analyzer working date. Default.
 PREV – The previously scheduled activation date of the rule,
determined when the rule is ordered by a balancing mission. If
the rule is not scheduled by a mission, the previous working
date is used.
 NEXT – Next scheduling date (determined when the rule is
ordered by a balancing mission). If the rule is not scheduled by
a mission, the next working date is used.
 **** – Any schedule date.
 $$$$ – Any schedule date.
 mmdd – Month and day of the schedule date of the job.
 ddmm – Day and month of the schedule date of the job.
The **** or date reference can only be used when opt is set to –
(delete). When **** or $$$$ is specified, prerequisite conditions
with the same name and any date reference are deleted.

opt Indicates whether to add or delete the specified condition.


Mandatory.
 + – Add (create) the prerequisite condition
 – – Delete the prerequisite condition

General Information
When a DO COND statement is specified, the designated prerequisite conditions are added to or deleted
from the IOA Conditions file according to the specified opt value.
A prerequisite condition can define any user-specified situation. The following are examples of
prerequisite conditions:
ACCT-IN-BALANCE
RESTORE-FILE-G0
SALARY-OK

Prerequisite conditions are the means by that the user can define and implement rule execution
dependencies, including rule-to-rule dependencies or rule dependencies based on successful completion
of a manual task (such as correction of errors).
Prerequisite conditions created by a DO COND statement can trigger (or stop) the activation of other rules
or the execution of processes in Control-M, Control-D, and other environments.

379
Control-M/Analyzer User Guide

Prerequisite conditions deleted by statement DO COND can stop the execution of rules, missions, and jobs
that require those prerequisite conditions.
If the prerequisite condition to be added already exists, or the prerequisite condition to be deleted does
not exist, the Control-M/Analyzer rule continues executing but returns the value 4 in system variable
SYSRC.
Each prerequisite condition is associated with its specified date reference that identifies different runs of
the same job on different scheduling dates.
If two or more DO COND statements contradict one another, the last executed statement overrides the
preceding statements.
Control-M/Analyzer AutoEdit, System and Local variables can be embedded in the condition of a DO COND
statement. These variables are resolved (replaced) at time of rule execution. For additional information on
AutoEdit processing, see Control-M/Analyzer Variables (on page 222).

Example
Prerequisite condition JOBNAME_OK is added if the data is balanced. This prerequisite condition is used to
start a flow of jobs in Control-M.
Figure 193 DO COND Statement Example
LIBRARY : CTB.PROD.RULES RULE : RULCURR
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE CHECK UPON C
ON DATA
ALWAYS
DO PRINT = TOTAL SUM IS : %%SUM F C
DO
IF SUM > 1000000.00 C
DO SHOUT TO U-M18 URGENCY R
= PLEASE CHECK CURRENCY FILE; SUM COMPUTED IS %%SUM
DO REMARK = SUM IS OVER 1000000.00 SUM=%%SUM

DO TERMINAT = NOTOK COD 0055


DO
ELSE
DO REMARK = SUM IS NOT OVER 1000000: SUM=%%SUM
DO COND = %%SYSJOBNAME_OK ODAT +
DO TERMINAT = OK COD 0000
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
PLEASE FILL IN RULE DEFINITION. 14.59.08

380
Control-M/Analyzer User Guide

DO EXIT: Automated Balancing Statement


Immediately terminates execution of the current block. Control passes to the statement that called the
block if there is one. Otherwise, control passes to the next block in the rule.
Figure 194 DO EXIT Statement Format

Optional. Statement DO EXIT can be used in any ON statement of any EXECUTE block. However,
statement DO EXIT is usually used in conjunction with a WHEN statement or an IF/ELSE statement.
Type the word EXIT (or its abbreviation EXI) next to the DO on the Rule Definition screen.

Example
In a periodic sales and commissions report, the salesmen are listed in order of decreasing sales volume.
The "top salesman" is the first one listed in the report. This example uses statement DO EXIT to
terminate the extraction process after the name of the top salesman in department 50x has been
extracted.
Figure 195 DO EXIT Statement Example
EXECUTE 'DD'
ON DATA
ALWAYS
DO BLOCK 'READ'
DO TERMINATE RESULT OK USER_CODE 444
EXECUTE 'READ'
ON_FILE 'ACTG.SALES.MNTHLY(SORTDOWN)' ON_PARM MODE PG
WHEN FLINE 1 TLINE 999 FCOL 13 TCOL 14 SEARCH '50'
DO EXTRACT 'TOP_SALE' LEVEL 0 LINE +0 FCOL 20 TCOL 39
DO PRINT DATA 'TOP SALESMAN = %%TOP_SALE'
DO EXIT

Input file "ACTG.SALES.MNTHLY(SORTDOWN)" contains the following lines:

381
Control-M/Analyzer User Guide

1 MONTHLY SALES REPORT


EMPLOYEE DPT SALES PERIOD DOLLAR
NUMBER NUM EMPLOYEE NAME FROM TO VOLUME
---------------------------------------
000187 507 MURPHY CHRISTOPHER 01/01/00 31/01/00 284,817
000132 505 BRADY GREG 01/01/00 31/01/00 281,224

The output of this rule is: TOP SALESMAN = MURPHY CHRISTOPHER


The DO EXIT statement is often used to terminate the current block when a specified condition occurs or
the needed information is found.
In the example above, block READ is terminated after "50" is located in columns 13-14 and the desired
information has been extracted and printed. This avoids looking through the entire file when information
is needed from only one line.

DO EXTRACT: Automated Balancing Statement


Assigns a value to a Control-M/Analyzer Database, AutoEdit, or Local variable. The value assigned to the
variable is extracted from the dataset being processed by the current EXECUTE block.
Figure 196 DO EXTRACT Statement Format

Optional. The DO EXTRACT statement is not available in an EXECUTE block containing an ON DATA
statement.
Type the word EXTRACT (or its abbreviation EXT) to the right of the DO parameter label on the Rule
Definition screen. Press Enter and the = prompt with the following fields is displayed:

382
Control-M/Analyzer User Guide

Table 225 DO EXTRACT Statement Fields

Field Description

varname Name of the AutoEdit, Database, or Local variable in which the


extracted information is to be stored. Mandatory.

LEVEL Level of the WHEN statement in the current WHEN criteria that is to
be used as a reference for this extraction. The default is the current
level (which can be specified as level 0). See statement WHEN for
additional information. Optional.

LINE Specifies how many lines Control-M/Analyzer should skip when


positioning within the data source before extracting. A signed (+/-)
3-digit number must be specified. Mandatory. Valid values are
specified and described in Table 226.

COL Specifies the column range from which to extract data, comprised
of:
 col_from – A 4-digit or signed 3-digit number must be specified.
Mandatory.
 col_until – A 4-digit or signed 3-digit number must be specified.
Mandatory.
Valid values are specified and described in Table 226.
Notes: Line and column positions can also be specified using
Relative Values (for example, the column at which the WHEN string
was found plus an offset value). For more information, see General
Information (on page 385).
The number of columns in the COL range cannot exceed 100
because the maximum length of the variable value (after resolving
%% operators, if any) is 100 bytes.

383
Control-M/Analyzer User Guide

Field Description

PROCESS Type of processing to apply to the extracted value before setting


the variable. Optional. Built-in processes all begin with the letter B.
The following built-in processes are available:
 BBINC – Extracts the binary character equivalent and converts it
to EBCDIC.
 BBIND – Extracts the binary double-word equivalent and
converts it to EBCDIC.
 BBINF – Extracts the binary fullword equivalent and converts it
to EBCDIC.
 BBINH – Extracts the binary halfword equivalent and converts it
to EBCDIC.
 BFLTB – Removes all blanks (including blanks in the middle of
the string).
 BFNUM – Converts formatted numbers to standard
mathematical format.
 BFNUME – Converts European numbers to standard
mathematical format.
 BPADZ – Replaces leading blanks with zeros.
 BTLOWER – Converts characters to lowercase.
 BTRIMB – Removes leading and trailing blanks.
 BTRIML – Removes leading blanks.
 BTRIMR – Removes trailing blanks.
 BTUPPER – Converts characters to uppercase.
 BUNPK – Converts packed format numbers to standard

384
Control-M/Analyzer User Guide

Field Description
mathematical format.
 BUNPKn – Converts packed format numbers to standard
mathematical format, including n decimal places.
 BUPROC – Calls a user defined process.
 BWn – Extracts the nth word from a string.
 BXuvwxyz – Filters specified characters (uvwxyz) from the data.
 BZONED – Converts zoned decimal numbers to standard
decimal character format.
 BCPROCn – Performs a series of processes.
For more information about most of these processes, see DO
EXTRACT Processes (on page 389).
User-defined processes must begin with the letter U. User Exit
CTBX010 can be modified to call user-defined processes. For
information about User Exit CTBX010, see the IOA.SAMPEXIT
library.
For information about compiling and linking member CTBX010, see
the INCONTROL for z/OS Installation Guide.

TYP Type of extraction to perform when setting the variable. Optional.


Valid values are:
 ' ' (Blank) – The value extracted from the data source is stored
in varname (overriding the previous value of varname).
 SU – The value extracted from the data source is added to the
previous value of varname (for the current rule invocation) and
the sum is stored in varname.
 AV – The average of the value extracted from the data source
and previous values of varname (from the current rule
invocation) is calculated and stored in varname.

General Information
DO EXTRACT extracts information that is located in the specified column range on the specified line. The
line number and column range can contain the following types of values:

385
Control-M/Analyzer User Guide

Table 226 Valid DO EXTRACT Line Number and Column Range Values

Value Description

Absolute Column Explicit column numbers of a line relative to the line located by the
Values current WHEN statement.
Example
LINE +003 COL 0052-0060

Relative Values Line numbers must be and column numbers may be specified with
a + (plus) or – (minus) prefix:

+nnn nnn lines or columns after the current position (located by the
current WHEN statement). +000 specifies the same line or column
located by the current WHEN statement.

-nnn nnn lines or columns before the current position (located by the
current WHEN statement).
Example
LINE +005 COL +010 - +020
Line specifications and relative column specifications are relative to
the line and first column of the location where the search string
specified by WHEN criteria was found.
The relevant WHEN statement is at the WHEN level specified by the
LEVEL parameter of statement DO EXTRACT.

The default LEVEL is zero, which refers to the last WHEN before the DO EXTRACT statement.
Control-M/Analyzer AutoEdit variables and Local variables can be embedded in the varname parameter of
statement DO EXTRACT. The variables are resolved (replaced) at time of rule execution. For additional
information on AutoEdit processing, see Control-M/Analyzer Variables (on page 222), and in particular
Passing Variables to Blocks, Rules and User Routines (on page 224).

Examples
A report is provided below to illustrate uses of statement DO EXTRACT. The report shows the status of
accounts receivable for a company. It is formatted as follows:
 Every account starts on a new page. An account may span several pages. In this case, the word
CONTINUED appears in the STATUS column at the bottom of each page (except the last) for that
account.
 If an account has an outstanding balance, the balance is printed after the words TOTAL DUE:
If the account has no outstanding balance, the words PAID IN FULL are displayed instead.

386
Control-M/Analyzer User Guide

 The page number is printed at the top of each page, prefixed by the word PAGE. There is a maximum
of 60 lines on each page.
 Each line of the report starts in column 2. (The first column is reserved for ASA-code control character
symbols.)
Note: Column numbering lines have been provided at the top and bottom of the sample report on the
next page for your convenience. These lines are not actual report lines.
The following examples are based on this sample report.
Figure 197 Sample Report with DO EXTRACT Examples
---+----1----+----2----+----3--——+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2----+—

ACCOUNTS RECEIVABLE DEPARTMENT DATE 28/12/99 PAGE 000001

C L I E N T H I S T O R Y D E T A I L FROM 01/01/99 TO 05/05/99


| ACCOUNT MAIN ACCOUNTING CONS. (MAC) | INVOICE # | INVOICE DATE | AMOUNT | AMOUNT DUE | STATUS
+-------------------------------------------------------------------------------------------------------------------------
| | CJ98443 | 03/03/99 | 245.00| 0.00 |
| | MJ24545 | 05/04/99 | 10344.40| 0.00 |
| | RJ10030 | 01/02/99 | 5329.39| 0.00 |
| | RJ12233 | 02/02/99 | 5000.00| 0.00 |
| | RJ30021 | 03/02/99 | 16670.10| 0.00 |
| | RJ32991 | 02/03/99 | 30300.44| 0.00 |
| | RJ33939 | 03/03/99 | 900.25| 0.00 |
| | RJ38001 | 05/04/99 | 1000.23| 0.00 |
| | RJ93043 | 05/04/99 | 415.89| 0.00 |
+-------------------------------------------------------------------------------------------------------------------------
| TOTALS | | | 70205.70| 0.00 | PAID IN FULL

ACCOUNTS RECEIVABLE DEPARTMENT DATE 28/12/99 PAGE 000002

C L I E N T H I S T O R Y D E T A I L FROM 01/01/99 TO 05/05/99


| ACCOUNT GENERAL COMP. SYSTEMS (GCS)| INVOICE # | INVOICE DATE | AMOUNT | AMOUNT DUE | STATUS
+-------------------------------------------------------------------------------------------------------------------------
| | 100322 | 02/01/99 | 1000.00 | 1000.00 |
| | 100400 | 02/01/99 | 500.00 | 500.00 |
| | 100405 | 02/01/99 | 500.00 | 500.00 |
| | 100520 | 02/02/99 | 333.34 | 333.34 |
| | 100560 | 02/02/99 | 3000.00 | 3000.00 |
| | 100561 | 02/02/99 | 250.00 | 250.00 |
| | 100678 | 02/02/99 | 1000.00 | 1000.00 |
| | 200001 | 01/03/99 | 250.00 | 250.00 |
| | 200012 | 01/03/99 | 333.33 | 333.33 |
| | 200300 | 01/04/99 | 500.00 | 500.00 |
| | 200456 | 01/04/99 | 500.00 | 500.00 |
| | 202533 | 05/04/99 | 1000.00 | 1000.00 |
| | 300003 | 12/04/99 | 250.00 | 250.00 |
| | 340203 | 26/04/99 | 333.33 | 333.33 |
+------------------------------------------------------------------------------------------------------------------------
| | | | | | CONTINUE

ACCOUNTS RECEIVABLE DEPARTMENT PAGE 000003

C L I E N T H I S T O R Y D E T A I L FROM 01/01/99 TO 05/05/99


| ACCOUNT GENERAL COMP. SYSTEMS (GCS)| INVOICE # | INVOICE DATE | AMOUNT | AMOUNT DUE | STATUS
+-------------------------------------------------------------------------------------------------------------------------
| | 343211 | 26/04/99 | 500.00 | 500.00 | CONTINUED
| | 350032 | 04/05/99 | 1000.00 | 1000.00 |
| | 520033 | 05/05/99 | 500.00 | 500.00 |
| | 540050 | 05/05/99 | 2000.00 | 2000.00 |
| | 540051 | 05/05/99 | 1000.00 | 1000.00 |
| | 540052 | 05/05/99 | 250.00 | 250.00 |
+-------------------------------------------------------------------------------------------------------------------------
| TOTALS | | | 15000.00 | 15000.00 | TOTAL DUE: 15000.00

ACCOUNTS RECEIVABLE DEPARTMENT DATE 28/12/99 PAGE 000004

C L I E N T H I S T O R Y D E T A I L FROM 01/01/99 TO 05/05/99


| ACCOUNT NATIONAL BANK | INVOICE # | INVOICE DATE | AMOUNT | AMOUNT DUE | STATUS
+-------------------------------------------------------------------------------------------------------------------------
| | B7003003 | 02/02/99 | 1800.00 | 300.00 |
| | B7003420 | 03/03/99 | 2700.00 | 2700.00 |
| | B7004009 | 05/04/99 | 1500.00 | 1500.00 |
| | B7018700 | 05/05/99 | 500.00 | 500.00 |
+-------------------------------------------------------------------------------------------------------------------------
| TOTALS | | | 5000.00 | 5000.00 | TOTAL DUE: 300.00

1 1 1
---+----1----+----2----+----3--——+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2----+—

387
Control-M/Analyzer User Guide

Example 1
String TOTAL DUE: is located and the total amount owed extracted. The rule then stores the total amount
owed into Control-M/Analyzer Local variable TOTAL_OWED.
Figure 198 DO EXTRACT Example 1 from Sample Report
LIBRARY : CTB.PROD.RULES RULE : CALCTOT
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M18B GROUP ACCOUNTS
UPDATED 05/05/99 - 15:30:05 BY M18B
DESC CALCULATE TOTAL OUTSTANDING BALANCE OWED THE COMPANY
OPTIONS
===========================================================================
EXECUTE GETOWED UPON C
ON SYSOUT PROCST PGMST STEP12 DDNAME ACCREP JOBNM
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 006 - 060 COL 095 - 120 STOP AND/OR
STRING = TOTAL DUE:
DO EXTRACT = TOTAL_OWED
LEVEL 1 LINE +000 COL +011 - +018 PROCESS TYP
DO PRINT = %%TOTAL-OWED F C
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====
PLEASE FILL IN RULE DEFINITION. 13.47.53

Example 2
A summary report (that provides a list of company names and their financial status) is created.
 The company name is extracted from the same line in which the string ACCOUNT was found (for
example, Level 1 WHEN statement) using relative column values.
 The status of this company is extracted from the same line in which was found the string TOTALS (for
example, Level 2 WHEN statement). The actual status is extracted from relative columns.
Figure 199 DO EXTRACT Example 2 from Sample Report
LIBRARY : CTB.PROD.RULES RULE : SUMREP
COMMAND ===> SCROLL===> CRSR
+------------------------------------------------------------------------------+
OWNER M18B GROUP ACCOUNTS
UPDATED 09/09/99 - 15:30:05 BY M18B
DESC SUMMARIZE THE ORIGINAL REPORT
OPTIONS
============================================================================
EXECUTE REPORT UPON C
ON SYSOUT PROCST PGMST STEP01 DDNAME SYSUT2 JOBNM
MODE PG LINECT 0060
DATASTAMP
WHEN LINE 004 - 004 COL 004 - 010 STOP Y AND/OR A
STRING = ACCOUNT
STOP LINE 001 - 006 COL 002 - 010
STRING = .NP.
WHEN LINE 006 - 060 COL 004 - 010<+> STOP AND/OR
STRING = TOTALS
DO EXTRACT = NAME
LEVEL 1 LINE +000 COL +008 - +034 PROCESS TYP
DO EXTRACT = STATUS
LEVEL 2 LINE +000 COL +092 - +116 PROCESS TYP
DO PRINT = %%NAME-%%STATUS F C
DO
PLEASE FILL IN RULE DEFINITION. 14.43.36

388
Control-M/Analyzer User Guide

Example 3
The average invoice amount for each company is calculated and a report is produced in which the
company name and average invoice amount are listed.
An average extraction (TYP=AV) of the invoice amount of each company into a variable is performed (for
example, the invoice amount of each line that belongs to the current company is extracted and a
"running" average is calculated for this variable).
Figure 200 DO EXTRACT Example 3 from Sample Report
LIBRARY : CTB.PROD.RULES RULE : AVERAGES
COMMAND ===> SCROLL===> CRSR
+------------------------------------------------------------------------------+
EXECUTE CALCAVG UPON C
ON SYSOUT PROCST PGMST STEP01 DDNAME SYSUT2 JOBNM
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 005 - 005 COL 002 - 011 STOP Y AND/OR A
STRING = ACCOUNT
STOP LINE 006 - 060 COL 002 - 015
STRING = TOTALS
WHEN LINE 006 - 006 COL 001 - 020 STOP Y AND/OR A
STRING = ————
STOP LINE 007 - 060 COL 001 - 020
STRING = ————
WHEN LINE L02+001 - 060 COL 070 - 081 STOP AND/OR
STRING = .AL.
DO EXTRACT = FULLNAME
LEVEL 1 LINE +000 COL +008 - +034 PROCESS TYP
DO EXTRACT = SHRTNAME
LEVEL 1 LINE +000 COL +031 - +033 PROCESS TYP
DO BLOCK = CHKNAME ARG SHRTNAME,FULLNAME
DO EXTRACT = AVG%%SHRTNAME C
LEVEL 0 LINE +000 COL +000 - +011 PROCESS TYP AV
PLEASE FILL IN RULE DEFINITION. 14.09.00

DO EXTRACT Processes
Shown below are the DO EXTRACT processes available under Control-M/Analyzer.

BFNUM – Convert Formatted Numbers


The BFNUM process changes numbers from various non-European formats (for example, 1,000, 1,000.00,
$1000 or 1,000CR) to standard mathematical format (1000.00 or –1000.00) for purposes of calculation
and comparison.

389
Control-M/Analyzer User Guide

Formats accepted by the BFNUM process are:


 Leading dollar and cent signs (for example, $1,000).
 Leading or trailing minus sign (for example, –1,000 or 1,000–).
 Leading plus sign (for example, +1,000).
 Numbers with embedded commas (for example, 1,000,000.00).
 Trailing letters CR or DB (for example, 1,000CR or 1,000DB).
 Leading asterisks (for example, *1,000), that are often found in the amount field on checks.
Note: In non-European format, the decimal separator is a period and the thousands separator is a
comma. In European format, the usage of period and comma are reversed. To convert European format
numbers, see BFNUME – Convert European Style Numbers (on page 391).
The BFNUM process is performed according to the following steps:
1. Blanks, commas, dollar signs, cent signs, and asterisks are removed from the extracted data.
2. Control-M/Analyzer determines if the number is negative or positive. A number is negative if:
• A minus sign is before or after the number.
• The letters CR are after the number.
• The number is enclosed in parentheses.
A number is positive if:
• No indication that the number is negative exists.
• The number ends with the letters DB.
3. If the result is blank, Control-M/Analyzer assumes the number is zero.
4. If the number starts with a decimal point, Control-M/Analyzer inserts a zero before the decimal point
(for example, .75 is modified to 0.75).
Table 227 BFNUM – Convert Formatted Numbers Example

PROCESS Name Input Output

BFNUM 123.45 123.45

BFNUM (1,345.2) -1345.2

BFNUM $***.12CR -0.12

BFNUM $**1,344,567.23CR -1344567.23

390
Control-M/Analyzer User Guide

BFNUME – Convert European Style Numbers


The BFNUME process changes numbers from various European formats (for example, 1.000, 1.000,00,
$1000 or 1.000CR) to standard mathematical format (1000.00 or –1000.00) for purposes of calculation
and comparison.
Formats accepted by the BFNUME process are:
 Leading dollar and cent signs (for example, $1.000).
 Leading or trailing minus sign (for example, –1.000 or 1.000–).
 Leading plus sign (for example, +1.000).
 Numbers with embedded periods (for example, 1.000.000,00).
 Trailing letters CR or DB (for example, 1.000CR or 1.000DB).
 Leading asterisks (for example, *1.000), that are often found in the amount field on checks.
Note: In European format, the decimal separator is a comma and the thousands separator is a period. In
non-European format, the usage of period and comma are reversed. To convert non-European format
numbers, see BFNUM – Convert Formatted Numbers (on page 389).
The BFNUME process is performed according to the following steps:
1. Blanks, periods, dollar signs, cent signs, and asterisks are removed from the extracted data.
2. Control-M/Analyzer determines if the number is negative or positive. A number is negative if:
• A minus sign is before or after the number.
• The letters CR are after the number.
• The number is enclosed in parentheses.
A number is positive if:
• No indication that the number is negative exists.
• The number ends with the letters DB.
3. If the result is blank, Control-M/Analyzer assumes the number is zero.
4. If the number starts with a comma, Control-M/Analyzer inserts a zero before the comma (for
example, ,75 is modified to 0,75).
Table 228 BFNUME – Convert European Style Numbers Example

PROCESS Name Input Output

BFNUME 123,45 123.45

BFNUME (1.345,2) -1345.2

BFNUME $***,12CR -0.12

BFNUME $**1.344.567,23CR -1344567.23

391
Control-M/Analyzer User Guide

BPADZ – Replace Leading Blanks With Zeroes


The BPADZ process changes blanks found before the first digit of a number to zeroes.
Table 229 BPADZ – Replace Leading Blanks With Zeroes Example

PROCESS Name Input Output

BPADZ C‘ 100’ 000100

BPADZ C‘ 100.00’ 000100.00

BTLOWER and BTUPPER – Change Case


The BTLOWER and BTUPPER processes translate the extracted input to lowercase or uppercase
respectively. These processes are useful when all the data to be processed should be lowercase or
uppercase.
Table 230 BTLOWER / BTUPPER – Change Case Example

PROCESS Name Input Output

BTLOWER ABCabc abcabc

BTUPPER ABCabc ABCABC

BUNPK – Convert Packed Integers


The BUNPK process converts packed format integers to standard decimal character format. This process
must be run on packed format numbers to prepare them for calculation.
Note: Packed numbers with decimals should be converted with process BUNPKn.
Table 231 BUNPK – Convert Packed Integers Example

PROCESS Name Input Output

BUNPK Hex‘123456’ 123456

BUNPK Hex‘12345C’ 12345

BUNPK Hex‘12345D’ -12345

392
Control-M/Analyzer User Guide

BUNPKn – Convert Packed Numbers Including Decimals


The BUNPKn process converts packed format numbers to standard decimal format. The number of digits
to place after the decimal point is specified by the number n in the process name.
The number specified in the process name must be between one and nine.
Note: Packed numbers without decimals should be converted with process BUNPK.
BUNPKn works in two phases:
 The input number is first converted from packed to decimal format.
 The result is modified to contain the specified number of digits after the decimal point. The number of
digits after the decimal point is specified in the process name, for example, process BUNPK2 specifies
that two digits should be placed after the decimal point.
Table 232 BUNPKn – Convert Packed Numbers Including Decimals Example

PROCESS Name Input Output

BUNPK2 Hex‘123456’ 1234.56

BUNPK2 Hex‘12345C’ 123.45

BUNPK2 Hex‘12345D’ -123.45

BUNPK5 Hex‘12345C’ 0.12345

BUNPK7 Hex‘12345C’ 0.0012345

393
Control-M/Analyzer User Guide

BUPROC - Specify a User-Defined Process


Specifying BUPROC as the DO EXTRACT process statement enables the user to specify a user-defined
process that should be performed on the data (instead of a supplied Control-M/Analyzer process).
To specify a user-defined process:
 An expression must be specified that defines the user-defined process that should be performed.
Statement DO SET stores the desired user-defined process in System variable SYSEXTUPROC.
 The expression must include a reference to System variable SYSEXTVAL, that contains the value
extracted by statement DO EXTRACT. The value of this System variable is passed to the user-defined
process as an input parameter.
 The user-defined process must be specified before statement DO EXTRACT ... BUPROC is executed.
Figure 201 BUPROC - Specify a User-Defined Process Example

For additional information about System variables SYSEXTUPROC and SYSEXTVAL see Summary of
System Variables (on page 262).

BWn – Extract the nth Word From a String


The BWn process returns the nth word from a string. For example, the fifth word in a string can be
extracted by specifying number 5 in the process name.
The number specified in the process name must be a positive integer.
Words are delimited by spaces.
Note: If the number of words in a string is less than the number specified in the process name, a null
string is returned and warning message CTB249W is written to the Rule Activity report.

394
Control-M/Analyzer User Guide

Table 233 BWn – Extract the nth Word From a String Example

PROCESS Name Input Output

BW2 The totals are equal. totals

BW3 The totals are equal. are

BW4 The totals are equal. equal

BW7 The totals are equal. <null string>a

BXuvwxyz – Filter Characters


The BXuvwxyz process deletes those characters that follow the letters BX in the process name from the
data that is extracted into a variable. The name of the process is dynamic, based on the characters that
should be filtered (for example, excluded). Blanks cannot be filtered by this process.
A maximum of six characters can be specified in the process name for filtering. Every occurrence of each
character specified in the process name is deleted from the data that is extracted into a variable. Mask
characters are not supported. Blanks are not affected by this process.
Table 234 BXuvwxyz – Filter Characters Example

PROCESS Name Input Output

BX$ $1,000.00 1,000.00

BX,$ $1,000.00 1000.00

BX,.$ $1,000.00 100000

BX-*+ 12*7+8-9 12789

BX/ 04/04/00 040400

BXework New York NY

395
Control-M/Analyzer User Guide

BZONED – Convert Zoned Decimal Numbers


The BZONED process converts zoned decimal numbers to standard decimal character format for purposes
of calculation.
Table 235 BZONED – Convert Zoned Decimal Numbers Example

PROCESS Name Input Output

BZONED Hex‘C1’ 1

BZONED Hex‘D4’ -4

BZONED Hex‘F1F2F3C4’ 1234

BZONED Hex‘F1F2F3D4’ -1234

BZONED Hex‘F1F2F3F4F5’ 12345

BZONED Hex‘F1F2F3F4A5’ -12345

BZONED Hex‘F1F2F3F4B5’ -12345

BZONED Hex‘F1F2F3F4E5’ -12345

BCPROCn – Perform a Series of Processes


The BCPROC1 through BCPROC9 processes are meaningful user-defined sequences of built-in and/or
user-defined processes specified by statement DO SET. The definition of BCPROCn remains effective until
the rule terminates unless its corresponding System variable, SYSCPROCn, is redefined during the rule.
See "SYSCPROCn" in Summary of System Variables (on page 262) for more information about defining
System Variables SYSCPROC1 ... SYSCPROC9. For more information, see DO SET: Automated Balancing
Statement (on page 418).
Some potentially useful sequences of built-in processes are illustrated in the example below:
Table 236 BCPROCn – Perform a Series of Processes Example

DO SET SYSCPROC1= Input Output

‘BX12345 BX67890 BTUPPER’ R22ed S9ox RED SOX

‘BW3 BX,.-: BTUPPER’ Dear Ms. Smith: SMITH

‘BX-/: BFLTB’ 12:34 56/78 12345678

396
Control-M/Analyzer User Guide

DO GETMEM: Automated Balancing Statement


Reads an AutoEdit member, enabling the use of its symbols for AutoEdit processing.
Figure 202 DO GETMEM Statement Format

Optional. Type the word GETMEM (or its abbreviation GE) next to the DO in the Rule Definition screen.
When Enter is pressed, the = prompt and the following fields are displayed:
Table 237 DO GETMEM Statement Fields

Field Description

member Name of the member. Mandatory.

LIBSYM Name of the library that contains the member. Mandatory.

General Information
AutoEdit variables can be used to pass information between Control-M/Analyzer rules and between
Control-M/Analyzer and other INCONTROL products (Control-M, Control-D, Control-O, and so on). The
following statements access AutoEdit members:
 DO GETMEM enables subsequent actions of the rule to access (by AutoEdit statements or DO SET
statements) AutoEdit variables contained in the specified AutoEdit member.
 DO ADDSYM adds an AutoEdit variable to an AutoEdit member.
 DO PUTMEM writes the AutoEdit member back to its library for future use.
Several AutoEdit members can be specified. If the same AutoEdit variable exists in more than one
AutoEdit member, the variable in the last specified member is used.
If a Local variable and an AutoEdit variable have the same name, the Local variable is resolved.
Use statement DO SET to assign a new value to an existing AutoEdit variable:

397
Control-M/Analyzer User Guide

DO SET %%A='5'

Also use statement DO SET to assign a new value to an existing Local variable:
DO SET A='6'

Use statement DO ADDSYM to add new variables to a member read by statement DO GETMEM. The
entire member (including new variables) should be written back to the Database by statement DO
PUTMEM.
If an AutoEdit member is read by statement DO GETMEM but its AutoEdit variables are not written back
to the Database by statement DO PUTMEM, a warning message is placed in the sysout of the job.
Control-M/Analyzer AutoEdit variables and Local variables (preceded by the %% operator) can be
embedded in parameters of statement DO GETMEM. The variables are resolved (replaced) at time of rule
execution. For additional information on AutoEdit processing, see Control-M/Analyzer Variables (on page
222), and in particular Passing Variables to Blocks, Rules and User Routines (on page 224).
The existence of the library and member is checked when the rule is executed and not when the rule is
created or modified.
For more information, see DO ADDSYM: Automated Balancing Statement (on page 364), and DO
PUTMEM: Automated Balancing Statement (on page 412).

Example
Statement DO GETMEM reads member TOTALS from library CTB.PROD.SYMBOLS and makes the values
of all the AutoEdit variables in this member available to the current Control-M/Analyzer rule.
Figure 203 DO GETMEM Statement Example
LIBRARY : CTB.PROD.RULES RULE : UPDAUTO
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M64 GROUP OPERATIONS
UPDATED 07/07/00 - 12:19:03 BY M64
DESC UPDATE AUTO-EDIT VARS WITH CONTROL-M/ANALYZER DATABASE VAL

OPTIONS
===========================================================================
EXECUTE UPDATE UPON C
ON DATA
ALWAYS
DO GETMEM = TOTALS
LIBSYM CTB.PROD.SYMBOLS
DO SET = %%APPLTOT=DB_ACCOUNT.APPL_TOTAL.@G0 C
DO PUTMEM = TOTALS
LIBSYM CTB.PROD.SYMBOLS
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 17.50.35

398
Control-M/Analyzer User Guide

DO GOTO: Automated Balancing Statement


Provides "GO TO" logic by directing processing flow to the LABEL of another group of statements in the
current EXECUTE block.
Figure 204 DO GOTO Statement Format

Optional. The DO GOTO statement is available only in an EXECUTE block containing an ON DATA
statement.
Type the word GOTO (or its abbreviation GO) next to the DO in the Rule Definition screen. When Enter
is pressed, the following field is displayed:
Table 238 DO GOTO Statement Fields

Field Description

LABEL Name of the LABEL that precedes the statements to process. LABEL
can have a maximum of 8 characters. The specified LABEL name
should match an existing LABEL name in the current EXECUTE
block. Mandatory.

General Information
The DO GOTO statement provides non-sequential program execution (branching) within a block. When a
DO GOTO statement is encountered during rule processing, Control-M/Analyzer searches for the
corresponding LABEL name in the current block. When found, the statements following the LABEL name
are executed. Processing flow does not return to the point after the DO GOTO statement.

399
Control-M/Analyzer User Guide

Example 1
If variable TOTAL or variable AVERAGE (extracted from the report by a previous EXECUTE block) is not
within the specified range, rule processing flow proceeds directly to label ERROR using statement DO
GOTO. The rule then terminates NOTOK.
Figure 205 DO GOTO Statement – Example 1
LIBRARY : CTB.PROD.RULES RULE : CHKACC
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE CHECK UPON C
ON DATA
ALWAYS
DO PRINT = CHECKING ACCOUNTS REPORT - SYSDATE, SYSTIME F C
DO
IF TOTAL>200 C
DO PRINT = TOTAL CHECKED AND IS ACCORDING TO EXPECTATIONS. F C
DO
ELSE
DO PRINT = TOTAL NOTOK, PLEASE CHECK ... F C
DO GOTO LABEL ERROR
DO
IF AVERAGE>150 AND AVERAGE<2000 C
DO PRINT = AVERAGE CHECKED AND IS IN THE CORRECT RANGE. F C
DO
ELSE
DO PRINT = AVERAGE NOT IN THE RIGHT RANGE, PLEASE CHECK ... F C
DO GOTO LABEL ERROR
DO
ALWAYS
DO TERMINAT = OK COD 0000
DO
LABEL: ERROR
ALWAYS
DO TERMINAT = NOTOK COD 3333
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 10.35.56

400
Control-M/Analyzer User Guide

Example 2
The person who has the highest salary in the organization is located. A single loop is performed, during
that the salaries are examined and the highest salary determined. The loop is implemented using
statement DO GOTO. Local variable I is the number of salaries to be examined. Local variable J is a
counter that was previously set to zero.
Figure 206 DO GOTO Statement – Example 2
LIBRARY : CTB.PROD.RULES RULE : MAXSAL
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE CHECK UPON C
ON DATA
ALWAYS
DO SET = MAX_SALARY=0 C
DO SET = MAX_COUNTER=0 C
DO
LABEL: LOOP
IF SALARY%%J > MAX_SALARY C
DO SET = MAX_SALARY=SALARY%%J C
DO SET = MAX_COUNTER=J C
DO
IF J<I C
DO SET = J=J+1 C
DO GOTO LABEL LOOP
DO
ALWAYS
DO PRINT = THE MAXIMUM SALARY IS %%MAX_SALARY F C
DO PRINT = IT IS EARNED BY %%PERSON%%MAX_COUNTER F C
DO
PLEASE FILL IN RULE DEFINITION. 11.27.52

401
Control-M/Analyzer User Guide

DO MAIL: Automated Balancing Statement


Sends an e-mail message to the specified recipients.
Figure 207 DO MAIL Parameter Format

Optional. Type MAIL (or its abbreviation MA) in the DO field and press Enter. The following
subparameters are displayed:

402
Control-M/Analyzer User Guide

Table 239 DO MAIL Subparameter Formats

Subparameters Description

TO Destination of the message. Mandatory. Valid values are:


 the full e-mail address
 a recipient name
If you use a recipient name, the full e-mail address is supplied by
the IOAPARM member in the IOA PARM library. The IOAPARM
member also includes the value of the DFLTSFFX field, which
specifies the e-mail address suffix (such as MAIL.DOMAIN.COM),
the SMTP STC name, and the HOST name.
Note: The @ character is taken from the ATSIGN parameter in the
IOAPARM member.
 the nick name or group name defined in MAILDEST member.
For more information regarding MAILDEST member, see the
INCONTROL for z/OS Administrator Guide.

CC Destination to which a copy of the message is to be sent. Optional.


Valid values are:
 the full e-mail address
 a recipient name
If you use a recipient name, the full e-mail address is supplied by
the IOAPARM member in the IOA PARM library. The IOAPARM
member also includes the value of the DFLTSFFX field, which
specifies the e-mail address suffix (such as MAIL.DOMAIN.COM),
the SMTP STC name, and the HOST name.
Note: The @ character is taken from the ATSIGN parameter in the
IOAPARM member.
 the nick name or group name defined in MAILDEST member.
For more information regarding MAILDEST member, see the
INCONTROL for z/OS Administrator Guide.

SUBJ Message subject of up to 70 characters. Optional.

TEXT Message text of up to 255 text lines, each with a maximum of 70


characters. Optional.

General Information
The specified e-mail is sent to the specified destinations when the accompanying ON statement criteria
are satisfied. Although e-mail can be sent using a DO SHOUT statement, the DO MAIL statement provides
the following advantages:

403
Control-M/Analyzer User Guide

 Using DO MAIL, you can specify any number of TO and CC recipients. With DO SHOUT, you must
specify the mail destination prefix, and you must define the address in the MAILDEST table.
 Using DO MAIL, the e-mail text can exceed 70 characters. Both system and user-defined AutoEdit
variables are supported in the subject line and message text. These variables are resolved when the
DO MAIL statement is processed.
Note: The resolved value of an AutoEdit variable is truncated after 70 characters.
For information on the use of AutoEdit variables, see AutoEdit Variables (on page 256).
The TO and CC Subparameters
The TO and CC subparameters can contain more than one mail name address. When a value is specified
in the TO or CC field, a new empty line is displayed so that an additional value can be specified (up to a
maximum of 255 lines).
Multiple addresses, separated by a semicolon (;), can be specified on a line.
If an address exceeds the length of a full line, it can be continued on the following line.

Example
If the job is not run due to a JCL error, send an e-mail to the relevant users:
Figure 208 DO MAIL Parameter Example
JOB: SACALC01 LIB CTM.PROD.SCHEDULE TABLE: SALARY
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
OUT
AUTO-ARCHIVE Y SYSDB Y MAXDAYS MAXRUNS
RETENTION: # OF DAYS TO KEEP 030 # OF GENERATIONS TO KEEP
SYSOUT OP (C,D,F,N,R) FROM
MAXRERUN RERUNMEM INTERVAL FROM
STEP RANGE FR (PGM.PROC) . TO .
ON PGMST ANYSTEP PROCST CODES JNRUN A/O
DO MAIL
TO MAIL_ADDRESS_#1
TO MAIL_ADDRESS_#2
CC MAIL_ADDRESS_#3;MAILK_ADDRESS_#4
SUBJ WARNING MESSAGE
TEXT JCL ERROR IN SALARY JOB! PLEASE CORRECT ERRORS AND RERUN THE JOB
DO
ON PGMST PROCST CODES A/O
DO
SHOUT WHEN TIME + DAYS TO URGN
MS
======= >>>>>>>>>>>>>>>>>>> END OF SCHEDULING PARAMETERS <<<<<<<<<<<<<<<< =====

COMMANDS: EDIT, DOC, PLAN, JOBSTAT 11.17.00

404
Control-M/Analyzer User Guide

DO PRINT: Automated Balancing Statement


Prints a data string to the Control-M/Analyzer Rule Activity report.
Figure 209 DO PRINT Statement Format

Optional. Type the word PRINT (or its abbreviation PR) next to the DO on the Rule Definition screen.
When Enter is pressed, the = prompt and a field for specifying the data string are displayed.
Table 240 DO PRINT Statement FIelds

Field Description

data-string Data string to be printed. Mandatory. A maximum of 51 characters


can be specified in the displayed field.

F When set to Y (Yes), the F (Format) field provides one or more pairs
of lines for specifying the format of numeric data to be printed by
the Dynamic Print facility described below.

C When set to Y (Yes), the C (Continue) field provides one more line
containing a maximum of 59 characters for specifying the
data-string. Specifying N (No) in the C (Continue?) field closes the
continuation line.

General Information
The DO PRINT statement specifies data strings to be included in the Control-M/Analyzer Rule Activity
report (that is generated after each Control-M/Analyzer invocation) and in the SYSUSER file (that is part
of the sysout of the job that invoked the rule). The printed data can be formatted and/or directed to a file
referenced by DD statement SYSUSER or an alternative DD statement. For more information, see
Dynamic Print Formatting Facility (on page 407).

405
Control-M/Analyzer User Guide

The Rule Activity report also includes automatically generated system data. It can be viewed online by
selecting the R (Report) option for the associated rule in the Rule Activity display (screen BA). For more
information, see Rule Activity Display Facility (on page 157).
All types of Control-M/Analyzer variables can be embedded in the DO PRINT data string. Variables
containing %% are resolved (replaced) at time of rule execution.
Statement DO PRINT can print long strings with the following syntax:
DO PRINT=%%long-string-variable

where long-string-variable is the name of a long string variable such as SYSCURLINE, SYSLSTR1,
SYSLSTR2, and so on.
This syntax for long string variables supports the OUTDD parameter but does not support concatenation
with other strings or literal constants.

Example 1
The header for the report produced by Control-M/Analyzer as a result of the invocation of this rule is
prepared using DO PRINT statements.
Figure 210 DO PRINT Statement – Example 1
LIBRARY : CTB.PROD.RULES RULE : RULEMP
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M18B GROUP ADMIN
CREATED 08/08/00 - 15:30:05 BY M18B
DESC CHECK EMPLOYEES REPORT FOR BALANCING
OPTIONS
===========================================================================
EXECUTE PREPARE UPON C
ON DATA
LABEL: INIT
ALWAYS
DO SET = COUNTER=0 C
DO SET = ERRORS=0 C
DO PRINT = UNREASONABLE SICK/VACATION DAYS F C
DO PRINT = ================================= F C
DO PRINT = +—+———————-+——+——-+ F C
DO PRINT = | NAME | SICK | VAC | F C
DO PRINT = +—+———————-+———+——-+ F C
===========================================================================
EXECUTE INPUT UPON C
ON FILE FILENAME CTB.PROD.EMPREP
MODE PG LINECT 0060 DATASTAMP
PLEASE FILL IN RULE DEFINITION. 11.34.30

Example 2
This example illustrates the specification of variables containing the %% operator in statement DO
PRINT. These variables are replaced by their current value each time statement DO PRINT is performed.

406
Control-M/Analyzer User Guide

Figure 211 DO PRINT Statement – Example 2


LIBRARY : CTB.PROD.RULES RULE : DOSET
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE CHECK UPON C
ON DATA
ALWAYS
DO SET = COUNTER=COUNTER+1 C
DO
IF SICK > 90 VAC > 30 C
DO PRINT = | %%COUNTER | %%NAME | %%SICK | %%VAC F C
DO SET = ERRORS=ERRORS+1 C
DO
(ENTER "ALWAYS", "IF" OR "ELSE")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 13.11.29

Dynamic Print Formatting Facility


The Control-M/Analyzer Dynamic Print Formatting facility formats numeric values and text strings so that
they are positioned in the output field according to the specifications of the user. This facility enables the
user to produce reports (using statement DO PRINT) so that numbers and text are properly aligned (for
example, by decimal point). The user can determine:
 How many decimal digits should be printed. 100.78 can be printed as: 100.78, 100.780, or 100.7800.

407
Control-M/Analyzer User Guide

 Whether the minus sign should be printed to the left or right of the number. Negative 100.78 can be
printed as –100.78 or 100.78–.
 Which symbol should represent the decimal point. 100.78 can be printed as 100.78 or 100,78
(European format).
 Whether delimiters should be used to mark thousands, millions, and so on, 12345.88 can be printed
as 12345.88 or 12,345.88 or 12.345,88.
 Whether text strings should be padded with trailing blanks to fill an output field.
Figure 212 DO PRINT Statement Invoking the Dynamic Print Formatting Facility

The Dynamic Print Formatting facility is invoked by specifying Y (Yes) in the F (Format) parameter to the
right of the DO PRINT statement in the Rule Definition screen. When Enter is pressed, the parameters
described below are displayed.
Table 241 Fields in DO PRINT Statements when the Dynamic Print Formatting Facility is
Invoked

Field Description

OUTDD Name of the DD statement that references the file to which the
output string specified in statement DO PRINT will also be written.
Optional, but OUTDD or VAR should be specified. The default output
DD statement is SYSUSER. When any other value is specified, the
user must include the specified DD statement in the JCL for the job.

VAR The variable to be formatted. Must be a single Control-M/Analyzer


Local variable specified in this DO PRINT statement whose value is a
text string or a numeric in standard mathematical format (for
example, 100.88, 2.24, 1022). If more than one variable in the DO
PRINT statement must be formatted, use a separate continuation
line for each one. Optional, but VAR or OUTDD should be specified.

Note: 1,200 is not in standard mathematical format because it


contains a comma.

408
Control-M/Analyzer User Guide

Field Description

LEN Maximum length of the formatted output field. Must be an integer.


Valid values range from 1 through 133. Mandatory if VAR is
specified. Text is left justified and numbers are right justified in the
output field.
For more information on how this field is justified, see the
discussion in Dynamic Print Formatting Facility Examples (on page
409).

PREC Number of digits following the decimal point in the output value.
Must be an integer. Valid values are from 0 through 132 but at least
one less than the value specified for the LEN parameter. Default
value is 0. Optional, but should be specified if the value of VAR is
numeric. This parameter is ignored when the value of VAR is a text
string.

DELIMITER Yes or No flag that indicates whether a "thousands" separator will or


will not be used in numeric output. This parameter is ignored when
the value of VAR is a text string. Valid values are:
 Y – Each group of three digits is separated by a comma if
system variable SYSDECCHARa is set to period, or by a period
if system variable SYSDECCHAR is set to comma.
 N or blank – A "thousands" separator is not used. Default.

SIGN Position of the minus sign in formatted numeric output. Optional.


This parameter is ignored when the value of VAR is a text string.
Valid values are:
 R — The minus sign, if any, is placed at the right of the least
significant digit of the output value.
 L or blank — The minus sign, if any, is placed at the left of the
most significant digit of the output value. Default.

C (Continue?) When set to Y (Yes), this field displays another pair of lines (for
example, FORMAT VAR and LEN/PREC/DELIMITER/SIGN) for
specifying the output format of another variable. A maximum of 10
format statements can be specified.
Specifying N (No) in the C (Continue?) field closes the following
preexisting line.

Dynamic Print Formatting Facility Examples


This example scans a payroll file and prints a formatted table listing management personnel and their
salaries.

409
Control-M/Analyzer User Guide

In the salary field, each group of three digits is separated by a comma (if the SYSDECCHAR parameter is
set to period) or by a period (if the SYSDECCHAR parameter is set to comma). A "thousands" separator is
not used in the insurance, union dues and social security fields.
Negative values for salary or insurance are preceded by a minus sign. Negative union dues are followed
by a minus sign.
Figure 213 Dynamic Print Formatting Facility – Example
LIBRARY : CTB.WORK.SOLVRULE RULE : RULE4
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
EXECUTE PROCESS UPON C
ON FILE FILENAME CTB.WORK.SOLVREP(CTBREP3)
MODE DS LINECT 0000 DATASTAMP
WHEN LINE 001 - 999 COL 036 - 037 STOP AND/OR
STRING = .GT.40
DO EXTRACT = SOCIAL_SECURITY
LEVEL 0 LINE +000 COL 0045 - 0055 PROCESS TYP
DO EXTRACT = SALARY
LEVEL 0 LINE +000 COL 0036 - 0041 PROCESS BFNUM TYP
DO EXTRACT = INSURANCE
LEVEL 0 LINE +000 COL 0092 - 0097 PROCESS TYP
DO EXTRACT = UNION_DUES
LEVEL 0 LINE +000 COL 0081 - 0086 PROCESS TYP
DO EXTRACT = VACATION
LEVEL 0 LINE +000 COL 0107 - 0108 PROCESS TYP
DO PRINT = %%SOCIAL_SECURITY %%SALARY %%INSURANCE F Y C Y
%%UNION_DUES %%VACATION
OUTDD
FORMAT VAR SALARY C Y
LEN 010 PREC 002 DELIMITER Y SIGN
FORMAT VAR INSURANCE C Y
LEN 010 PREC 002 DELIMITER N SIGN
FORMAT VAR UNION_DUES C Y
LEN 010 PREC 002 DELIMITER N SIGN R
FORMAT VAR SOCIAL_SECURITY C
LEN 006 PREC 000 DELIMITER N SIGN
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
============================================================================

410
Control-M/Analyzer User Guide

Table 242 Dynamic Print Formatting Facility – Examples

Input Value LEN PREC DELIMITER SIGN SYSDECCHAR Output Value

123.45 10 2 Y . 123.45

4123.45 10 2 Y . 4,123.45

–4123.45 10 2 Y . –4,123.45

123.45 10 2 Y , 123,45

4123.45 10 2 Y , 4.123,45

–4123.45 10 2 N , –4123,45

123.45 10 2 Y R . 123.45

4123.45 10 2 Y R . 4,123.45

–4123.45 10 2 Y R . 4,123.45–

12.464 10 2 Y . 12.46

123.45 10 3 Y . 123.450

0 10 3 Y . 0.000

1232 10 3 N . 1232.000

The size of the fractional portion of the output value is adjusted to the value of the PREC parameter. If
the number of decimal digits after the point in the input variable is less than the value of PREC, zeroes are
added to it. If the number of decimal digits after the point in the input variable is greater than the value
of PREC, the last (least significant) digits are rounded.
The formatting facility allows for up to 16 digits to be displayed for a printed value, including the
fractional portion of that value. Values larger than 16 digits are rounded. For example, if the total length
of the value is 18 digits, then the last (least significant) two digits are rounded.

411
Control-M/Analyzer User Guide

DO PUTMEM: Automated Balancing Statement


Writes an AutoEdit member back to the library to that it belongs for future use by Control-M/Analyzer or
by other INCONTROL products.
Figure 214 DO PUTMEM Statement Format

Optional. Type the word PUTMEM (or its abbreviation PU) next to the DO in the Rule Definition screen.
When Enter is pressed, the = prompt and the following fields are displayed:
Table 243 DO PUTMEM Statement Fields

Field Description

member Name of the member. Mandatory.

LIBSYM Name of the library (44 character maximum) to which the member
belongs. Mandatory.

General Information
AutoEdit variables can be used to pass information between Control-M/Analyzer rules and between
Control-M/Analyzer and other INCONTROL products (Control-M, Control-D, Control-O, and so on). The
following statements access AutoEdit members:
 DO GETMEM enables subsequent actions of the rule to access (by AutoEdit statements or DO SET
statements) AutoEdit variables contained in the specified AutoEdit member.
 DO ADDSYM adds an AutoEdit variable to an AutoEdit member.
 DO PUTMEM writes the AutoEdit member back to its library for future use.
After DO PUTMEM is executed, AutoEdit variables belonging to the written member are deleted from
memory and are unavailable for referencing (unless the member is again read by a DO GETMEM
statement).

412
Control-M/Analyzer User Guide

If member-name has been read by a DO GETMEM statement and exists in library LIBSYM,
Control-M/Analyzer replaces the member with its current AutoEdit variables. If member-name has not
been previously read (by a DO GETMEM statement) and does not exist in the LIBSYM library,
Control-M/Analyzer creates the member. If member-name exists in the LIBSYM library but has not been
previously read, modifications to the AutoEdit variables are not retained when the DO PUTMEM statement
is performed. In this case, a runtime error occurs.
If an AutoEdit member is read by the DO GETMEM statement but its AutoEdit variables are not written
back to the Database by the DO PUTMEM statement, a warning message is placed in the sysout of the
job. The AutoEdit variable values are not saved.
Control-M/Analyzer AutoEdit variables and Local variables (preceded by the %% operator) can be
embedded in parameters of the DO PUTMEM statement. The variables are resolved (replaced) at time of
rule execution. For additional information on AutoEdit processing, see Chapter 3, "Control-M/Analyzer
Variables." For additional information on AutoEdit processing, see Control-M/Analyzer Variables (on page
222), and in particular Passing Variables to Blocks, Rules and User Routines (on page 224).
For more information, see DO ADDSYM: Automated Balancing Statement (on page 364), and DO GOTO:
Automated Balancing Statement (on page 399).

Example
Statement DO PUTMEM writes member TOTALS back to library CTB.PROD.SYMBOLS after the values of
certain AutoEdit variables in this member are changed by the rule.
Figure 215 DO PUTMEM Statement Example
LIBRARY : CTB.PROD.RULES RULE : UPDAUTO
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M64 GROUP OPERATIONS
UPDATED 08/08/00 - 12:19:03 BY M64
DESC UPDATE AUTO-EDIT VARS WITH CONTROL-M/ANALYZER DATABASE VALUE

OPTIONS
===========================================================================
EXECUTE UPDATE UPON C
ON DATA
ALWAYS
DO GETMEM = TOTALS
LIBSYM CTB.PROD.SYMBOLS
DO SET = %%APPLTOT=DB_ACCOUNT.APPL_TOTAL.@G01 C
DO PUTMEM = TOTALS
LIBSYM CTB.PROD.SYMBOLS
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====
PLEASE FILL IN RULE DEFINITION. 17.50.35

413
Control-M/Analyzer User Guide

DO REMARK: Automated Balancing Statement


Adds a user-defined remark to the Rule Activity report and the Rule Activity display (screen BA).
Figure 216 DO REMARK Statement Format

Optional. Type the word REMARK (or its abbreviation RE) next to the word DO in the Rule Definition
screen. When Enter is pressed, the = prompt and a field where the remark can be specified are
displayed. The remark can have a maximum of 50 characters. It must have at least one non-blank
character.

General Information
The DO REMARK statement adds a user-defined remark to the Control-M/Analyzer Rule Activity report and
the Rule Activity display (screen BA). The remark usually describes the results of the current
Control-M/Analyzer invocation. The remark can be displayed in the Rule Activity List screen to provide a
user-specified summary of invocation results.
If several DO REMARK statements are specified in the rule, only the last one is retained and added to the
Rule Activity report.
Control-M/Analyzer AutoEdit variables and Local variables (preceded by the %% operator) can be
embedded in the DO REMARK statement. These variables are resolved (replaced) at time of rule
execution. For additional information on AutoEdit processing see Control-M/Analyzer Variables (on page
222).
Example
Specify different remarks to be displayed on the Control-M/Analyzer Rule Activity display (screen BA)
according to the value of variable SUM.

414
Control-M/Analyzer User Guide

Figure 217 DO REMARK Statement Example


LIBRARY : CTB.PROD.RULES RULE : RULCURR
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
IF SUM > 1000000.00 C
DO SHOUT TO U-M18 URGENCY R
= PLEASE CHECK CURRENCY FILE; SUM COMPUTED IS %%SUM
DO REMARK = SUM IS OVER 1000000.00 SUM=%%SUM
DO COND = NOTOK-%%SYSJOBNAME 0704 +
DO TERMINAT = NOTOK COD 0055
DO
ELSE
DO REMARK = SUM IS NOT OVER 1000000.00 SUM=%%SUM
DO TERMINAT = OK COD 0000
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 11.44.30

415
Control-M/Analyzer User Guide

DO RULE: Automated Balancing Statement


Invokes another rule from within the current rule.
Figure 218 DO RULE Statement Format

Optional. Type the word RULE (or its abbreviation RU) next to the DO in the Rule Definition screen.
When Enter is pressed, the = prompt and the following fields are displayed:
Table 244 DO RULE Statement Fields

Field Description

name Name of the rule to be activated. name can have a maximum of 8


characters. Mandatory.

ARG Input and output arguments to be passed to the called rule. If


specified, arguments must be predefined Local or Database
variables separated by commas. A maximum of 50 arguments can
be specified. Optional.

Note: Database variables can be embedded in the ARG parameter


only if they have not yet been committed. After a Database variable
is committed, it cannot be specified in the ARG parameter.

When set to Y (Yes), the C (Continue?) field provides additional space for specifying variables. A
maximum of 10 lines can be opened. Specifying N (No) in the C (Continue?) field closes the following
preexisting line.

General Information
When the DO RULE statement is encountered during rule processing, Control-M/Analyzer invokes the
specified rule. When the specified rule finishes processing, processing flow continues sequentially from
the point after the DO RULE statement in the calling rule.

416
Control-M/Analyzer User Guide

Rule recursion (for example, a rule calling itself), whether explicit or implicit, is not permitted. A runtime
error occurs when recursion is detected.
The called rule is read from the libraries referenced by the DABRULE DD statement.
The return code of the called rule is placed in System variable SYSRC.
The calling rule may pass variables as input to the called rule, as explained above. These variables are
called rule arguments. Rule arguments must be Local or Database variables that have already been
initialized. The called rule may change the values of these arguments, causing the new values to be
returned to the calling rule.
The called rule refers to these arguments by specifying the RARGnn parameter, where nn is a number
from 1 to the actual number of passed arguments.
Control-M/Analyzer AutoEdit variables plus Local and Database variables (preceded by the %% prefix)
can be embedded in the ARG parameter of the DO RULE statement. The variables are resolved (replaced)
at time of rule execution. For additional information on AutoEdit processing, see Control-M/Analyzer
Variables (on page 222), and in particular Passing Variables to Blocks, Rules and User Routines (on page
224).
Control-M/Analyzer Database variables are committed (according to the method specified in the DO
COMMIT statement) when the rule terminates.
 If the rule was called by a job step, commitment occurs when the rule terminates.
 If the rule was called by another rule (by the DO RULE statement), commitment occurs when the
calling rule terminates.
After termination of the called rule, processing flow control returns to either the next step (in the job that
called the rule) or the calling rule – depending on that entity invoked the called rule.

417
Control-M/Analyzer User Guide

Example
Control-M/Analyzer rule COMPNET is invoked as a subroutine to calculate the net salary for each
employee.
Figure 219 DO RULE Statement Example
LIBRARY : CTB.PROD.RULES RULE : ADMSAL
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M18B GROUP ADMIN
UPDATED 08/08/00 - 15:30:05 BY M18B
DESC PRODUCE A SUMMARY SALARY REPORT FOR MANAGEMENT
OPTIONS
===========================================================================
EXECUTE INPUT UPON C
ON FILE FILENAME CTB.PROD.EMPREP
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 001 - 060 COL 013 - 014 STOP AND/OR
STRING = |
DO EXTRACT = NAME
LEVEL 0 LINE +000 COL +002 - +013 PROCESS TYP
DO EXTRACT = ID
LEVEL 0 LINE +000 COL +015 - +023 PROCESS TYP
DO EXTRACT = GROSS_SALARY
LEVEL 0 LINE +000 COL +080 - +090 PROCESS TYP
DO RULE = COMPNET ARG ID,GROSS_SALARY,NET_SALARY C
DO PRINT = %%NAME %%GROSS_SALARY %%NET_SALARY F C
DO
WHEN LINE - COL - STOP AND/OR
PLEASE FILL IN RULE DEFINITION. 12.52.47

DO SET: Automated Balancing Statement


Assigns values to Database variables, AutoEdit variables, Local variables and certain System variables.
Figure 220 DO SET Statement Format

Optional. Type the word SET (or its abbreviation SE) next to the DO in the Rule Definition screen. When
Enter is pressed, the = prompt and a field for the specification of an expression are displayed. The
expression must be specified according to the following format:
varname=value

where

418
Control-M/Analyzer User Guide

 varname is the name of a Control-M/Analyzer Database, AutoEdit, or Local variable.


 = must be typed in by the user as a separator between varname and value.
 value is the value to be assigned to the variable. The maximum length of the value of the variable
(after resolving %% operators, if any) is 100 bytes.
The value can be the result of an expression.
For additional information about Control-M/Analyzer expressions see Chapter 4, "Expressions and
Functions".
When set to Y (Yes), the C (Continue?) field provides additional space for specifying the expression. A
maximum of 10 additional lines can be opened. Entering N (No) in the C (Continue?) field closes the
following preexisting line.

General Information
varname can be a Control-M/Analyzer Database variable, AutoEdit variable, Local variable, or, in certain
cases, a System variable. For more information on setting variables see see Control-M/Analyzer Variables
(on page 222). The Summary of System Variables (on page 262) indicates that System variables can be
set by statement DO SET.
When varname is a Database variable, the variable name specified must adhere to certain naming
conventions. See Database Variable Reference Method (on page 230) for additional information.
Control-M/Analyzer AutoEdit variables and Local variables (preceded by the %% operator) can be part of
the variable name. These variables are resolved (replaced) at time of rule execution. The largest number
that can be handled by mathematical AutoEdit operations is 2 GB (2147483647). For additional
information on AutoEdit processing, see Control-M/Analyzer Variables (on page 222), and in particular
Passing Variables to Blocks, Rules and User Routines (on page 224).
For information about committing variables that have been assigned a value by statement DO SET, see
DO COMMIT: Automated Balancing Statement (on page 373) and Committing Database Variables (on
page 233).

Examples
Example 1
Initialize Control-M/Analyzer variables COUNTER and ERRORS before starting rule processing.

419
Control-M/Analyzer User Guide

Figure 221 DO SET Statement – Example 1


LIBRARY : CTB.PROD.RULES RULE : RULEMP
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M18B GROUP ADMIN
UPDATED 08/08/00 - 15:30:05 BY M18B
DESC CHECK EMPLOYEES REPORT FOR BALANCING
OPTIONS
===========================================================================
EXECUTE PREPARE UPON C
ON DATA
LABEL: INIT
ALWAYS
DO SET = COUNTER=0 C
DO SET = ERRORS=0 C
DO PRINT = UNREASONABLE SICK/VACATION DAYS F C
DO PRINT = ================================= F C
DO PRINT = +--+---------------+------+-----+ F C
DO PRINT = | | NAME | SICK | VAC | F C
DO PRINT = +--+---------------+------+-----+ F C
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE INPUT UPON C
PLEASE FILL IN RULE DEFINITION. 13.02.29

Example 2
Values are assigned to Control-M/Analyzer Local variables COUNTER and ERRORS during rule processing.
AutoEdit variables are used in statement DO PRINT. These variables are replaced by their current value
each time statement DO PRINT is performed.
Figure 222 DO SET Statement – Example 2
LIBRARY : CTB.PROD.RULES RULE : DOSET
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE CHECK UPON C
ON DATA
ALWAYS
DO SET = COUNTER=COUNTER+1 C
DO
IF SICK > 90 AND VAC > 30 C
DO PRINT = %%COUNTER %%NAME %%SICK %%VAC F C
DO SET = ERRORS=ERRORS+1 C
DO
(ENTER "ALWAYS", "IF" OR "ELSE")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 13.11.29

420
Control-M/Analyzer User Guide

DO SHOUT: Automated Balancing Statement


Sends a message to a specified destination.
Figure 223 DO SHOUT Statement Format

Type SHOUT (or its abbreviation SH) next to the DO in the Rule Definition screen.
When Enter is pressed, the following fields are displayed:
Table 245 DO SHOUT Statement Fields

Field Description

TO Destination of the message (1 through 16 characters). Mandatory.


Valid values are:
 U-userid or USERID-userid – Writes the message to the IOA Log
file under the specified user ID. userid must be 1 through 8
characters.
 OPER[–n]–Sends a rollable message to the operator console. n is
an optional 2-digit route code. For more detailed information
regarding route and descriptor codes, refer to the IBM publication
Routing and Descriptor Codes, GC38-1102.
 OPER2[–n]–Sends an unrollable, highlighted message to the
operator console. n is an optional 2-digit route code. If a route
code is not specified, the default routes are Master Console and
Programmer Information (1 and 11). For more detailed
information regarding route codes, refer to the IBM publication
Routing and Descriptor Codes, GC38-1102.

421
Control-M/Analyzer User Guide

Field Description

TO  TSO - loginid [;Nn | ;Mm | ;NnMm | ;Lname] – Sends the


message to the user identified by the specified logon ID
(continued)
(logonid). logonid is mandatory (1 through 7 characters).An
optional second value, indicating the computer and/or node (such
as Nn) of the TSO logonid, can be specified, as follows:
Under JES2:
Valid values are Nn, Mm or NnMm, where:
– m is the machine ID (the computer in JES2, not the
4-character SMF ID). For more information, see the
description of specifying IOA CPU in the discussion of the
customization process in the INCONTROL for OS/390
and z/OS Installation Guide.
– n is the 1 or 2 character JES/NJE node ID.
Under JES3:
The only valid value is Lname, where Lname is the logical JES
name of the machine (that is, the name as used in JES3
command *T, not the SMF system ID).
For more information, see the description of specifying IOA CPU
in the discussion of the customization process in the INCONTROL
for z/OS Installation Guide.

Note: A shout to a TSO user performs a TSO SEND command that


may require authorization at the receiving node.

 U-M: mail-name-prefix – Sends a message by mail to the


recipient identified by mail-name-prefix (1 through 12
characters).
 U-ECS – Sends messages to the Control-M/Enterprise Manager
user. For more information, see Shouting to Control-M/Enterprise
Manager (on page 423).

URGENCY Determines the priority level of the message. Valid values are:
 R – Regular. Default
 U – Urgent
 V – Very urgent

= Message text. Maximum length: 70 characters.


AutoEdit variables (both system and user-defined) are supported and
automatically resolved (replaced) when the SHOUT message is
issued. For AutoEdit usage information, see Control-M/Analyzer
Variables (on page 222), and Report Generation (on page 625).

422
Control-M/Analyzer User Guide

General Information
The message is sent to the required destination when the accompanying ON statement criteria are
satisfied.
The TO Subparameter
Specify TO=USERID-userid, to write the message to the IOA Log file under the user ID specified in the
parameter.
Specify TO=OPER[–n], to send the message to the operator console (route code n). If the n value is
omitted, the message is sent to all consoles to which route codes 1 or 11 are assigned. For more detailed
information regarding route and descriptor codes, refer to the IBM publication Routing and Descriptor
Codes, GC38-1102.
Specify TO=OPER2[–n], to send a highlighted, unrollable message is sent to the operator console (route
code n). If the n value is omitted, the message is sent to all consoles to which route codes 1 or 11 are
assigned. For more detailed information regarding route and descriptor codes, refer to the IBM publication
Routing and Descriptor Codes, GC38-1102.
Specify TO=TSO-id or T-id, to send the message is sent to the logonid. The Shout facility first searches
the IOA Dynamic Destination table for the specified ID. If the table contains an entry that matches the
value, the content of the entry is used as the target for the shouted message. (The entire TO field is
used. Therefore, when directing the message to a remote user, do not append Nn or Mm. Instead, do this
in the IOA Dynamic Destination table itself). For more information, see the description of Dynamic
Destination Tables in the INCONTROL for z/OS Administrator Guide.
If no matching ID is found in the Dynamic Destination table, the Shout facility assumes the specified ID is
a logonid. It then creates a TSO message that it hands over to MVS. MVS then sends the message to that
logonid. If the logonid does not exist, MVS cannot send the message, but no error message is generated.
When a second value is used, the message is sent to the TSO logonid in the specified computer or node
(machine ID). To determine the machine ID under JES2, specify JES command $LSYS.
Specify TO=U-M: mail-name-prefix to send the message by e-mail to the recipient identified by the prefix.
The full mail name address is supplied by the MAILDEST table in the IOA PARM library. For more
information about mail destinations, see the INCONTROL for z/OS Administrator Guide. The IOAPARM
member includes DFLTSFFX, the mail address suffix, such as MAIL.DOMAIN.COM, the SMTP STC name,
and the HOSTNAME.

Shouting to Control-M/Enterprise Manager


For Control-M/Analyzer to be able to shout to Control-M/Enterprise Manager, the following conditions
must be satisfied at the site:
1. Control-M/Enterprise Manager must be installed and the ECS parameter must be set to Y in member
IOAPARM in the IOA PARM library.
2. File MG2 (the Control-M/Enterprise Manager Shout File) must be defined.
3. The following parameters in the IOAPARM member in the IOA PARM library must be defined according
to how messages are targeted to Control-M/Enterprise Manager:
• If TO=OPER and TO=OPER2 messages must be sent to Control-M/Enterprise Manager, the
OPER2ECS parameter must be set to Y (Yes). Otherwise, it must be set to N (No).
When OPER2ECS is set to Y:

423
Control-M/Analyzer User Guide

o If these messages must also be sent to the MVS operator console, the OPER2CON parameter
must also be set to Y (Yes).
o If these messages must not also be sent to the MVS operator console, the OPER2CON
parameter must also be set to N (No).
• If TO=U-ECS messages must be sent to Control-M/Enterprise Manager, the UECS2ECS parameter
must be set to Y (Yes); otherwise, it must be set to N (No). Regardless of the value of this
parameter, these messages are also sent to Control-M/Analyzer and the IOA Log.
Once the above conditions are satisfied, messages can be shouted to Control-M/Enterprise Manager by
specifying a destination of TO=OPER or TO=OPER2 (without a route code qualifier), or TO=U-ECS.
Such messages are then placed by Control-M/Analyzer in the M2G file. Once the shouted message is in
the M2G file, the Control-M/Analyzer Application Server reads the file and sends the message to the
Control-M/Enterprise Manager user.
The URGENCY Subparameter
The URGENCY value indicates the urgency level of the message.
In addition, if the destination is USERID-userid (or U-userid), the user can control, according to urgency,
which messages are displayed when the IOA Log file is accessed. Urgent and very urgent messages are
highlighted on the screen. For more details, see IOA Log Facility (on page 195).

Example
TSO-user M18 is notified if the computed sum is more than 1,000,000.00.
Figure 224 DO SHOUT Statement Example
LIBRARY : CTB.PROD.RULES RULE : RULCURR
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
IF SUM > 1000000.00 C
DO SHOUT TO TSO-M18 URGENCY R
= PLEASE CHECK CURRENCY FILE; SUM COMPUTED IS &&SUM
DO REMARK = SUM IS OVER 1000000.00 SUM=%%SUM
DO COND = NOTOK-%%SYSJOBNAME 0704 +
DO TERMINAT = NOTOK COD 0055
DO
ELSE
DO REMARK = SUM IS NOT OVER 1000000.00 SUM=%%SUM
DO TERMINAT = OK COD 0000
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 13.52.20

424
Control-M/Analyzer User Guide

DO SYSOUT: Automated Balancing Statement


Specifies how job output should be handled.
Figure 225 DO SYSOUT Statement Format

Optional. Type the word SYSOUT (or its abbreviation SY) next to the DO in the Rule Definition screen.
When Enter is pressed, the following fields are displayed:
Table 246 DO SYSOUT Statement Fields

Field Description

OPT Processing option for the job output. Mandatory. Specify one of the
following codes:
 C—Change class of job output
 D—Delete job output (purge)
 N—Change destination of job output
 R—Release job output for printing

PRM If OPT=C, PRM specifies the name of the new class (one character).
If OPT=N, PRM specifies the name of the new destination (eight
characters). If OPT=D or OPT=R, PRM should be blank.

FRM Limits the application of DO SYSOUT to sysouts from the class


specified in this field. Optional.

General Information
When the DO SYSOUT statement is specified, Control-M/Analyzer tries to execute the DO SYSOUT
instruction.

425
Control-M/Analyzer User Guide

The DO SYSOUT statement can be invoked from an EXECUTE block containing any type of ON statement
(ON CLASS, ON DATA, and so on).
DO SYSOUT processing is performed only on closed sysout files that are in HELD state after being created
by previous steps of the job (for example, FREE=CLOSE was specified in the DD statement that created
the sysout files).
If the FRM (from class) parameter is blank, all of the held output of the job is processed. When the FRM
parameter is specified, only held sysouts that belong to the selected class are processed.
Table 247 Examples of Processing Job Sysout Field Settings

Value Description

OPT=D Delete. The held sysouts of the job are deleted (purged) from the
output queue.

OPT=R Release. The held sysouts of the job are released for printing.

OPT=C PRM=class The held sysouts of the job are moved to the specified output
class. The user must specify an existing, meaningful output class.

OPT=N PRM=newdest The held sysouts of the job are changed to a different output
destination. The user must specify an existing, meaningful output
destination.

Note: At JES3 sites, BMC recommends that the FRM parameter be specified (for example, FRM should not
be blank) because operations on all of the held output of the jobs cannot be performed in one DO
SYSOUT operation. To process the held sysouts of all jobs, specify separate DO SYSOUT statements for
each output class.

Special Considerations
DO SYSOUT requests are accumulated during block execution and performed when the block is exited.
No matter how many times the WHEN block is executed, a DO SYSOUT statement in a WHEN block is
processed only once, because successive executions of the same DO SYSOUT statement would be
meaningless.
"All sysout" operations (for example, DO SYSOUT operations where the FRM parameter is blank) override
specific class operations. For example, if you delete all the sysouts from the job, it does not matter that
other sysout operations have been specified. The entire output of the job is purged. Therefore, take
precaution when mixing specific class operations with "all sysout" operations.
Changing a sysout class to a released class changes the class name. However, it does not release the
sysout because the attributes do not change (according to JES logic). Likewise, changing a sysout class to
a dummy class does not purge the sysout because the attributes do not change (according to JES logic).

426
Control-M/Analyzer User Guide

Multiple DO SYSOUT Instructions


JES executes requests asynchronously. If two actions are specified for the same class (for
example, release and change class), they may or may not be performed in the order specified. This may
cause an error in one of the commands.
To overcome this problem, Control-M/Analyzer merges all output operations for the same class into one
JES request. For example, to change class and release, use the following two DO SYSOUT statements:
DO SYSOUT C Q FRM A
DO SYSOUT R FRM A

If you specify the following statements:


DO SYSOUT C Q FRM A
DO SYSOUT R FRM

The results are unpredictable, because the second example produces two JES requests: one for class A
and another for all held output.

Example
Check the output in output class X. If the extracted total matches the Database total, release the report
for printing.
Figure 226 DO SYSOUT Field Example
LIBRARY : CTB.PROD.RULES RULE : RULCURR
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER N52A GROUP ACCT
UPDATED 08/08/00 - 08:47:05 BY N52A
DESC CHECK WEEKLY ACCOUNTING REPORT
OPTIONS
===========================================================================
EXECUTE TOTALS UPON C
ON CLASS = X EXTWTR DEST FORM
MODE PG LINECT DATASTAMP
WHEN LINE 001 - 060 COL 025 - 029 STOP AND/OR
STRING = ’TOTAL’
DO EXTRACT = TOTAL
LEVEL LINE +000 COL 0031 - 0041 PROCESS TYP
DO
WHEN LINE 001 - 060 COL 025 - 029 STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE CHECK UPON C
ON DATA
IF TOTAL=DB_TOTAL C
DO SYSOUT OPT R PRM FRM
DO
ELSE
DO PRINT = A PROBLEM IS DETECTED; TOTALS DO NOT MATCH F C
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<< =====
PLEASE FILL IN RULE DEFINITION. 08.59.57

427
Control-M/Analyzer User Guide

DO TERMINAT: Automated Balancing Statement


Requests rule termination and specifies a condition code or user abend code. The rule is terminated after
this statement.
Figure 227 DO TERMINAT Statement Format

Type the word TERMINAT (or its abbreviation T) next to the DO in the Rule Definition screen. When
Enter is pressed, the = prompt and the following fields are displayed:
Table 248 DO TERMINAT Statement Fields

Field Description

result Determines the outcome of the balancing attempt. Mandatory.


Possible result values are:
 OK – Input is balanced. Execution is terminated with a condition
code.
 NOTOK – Input is not balanced and is not within reasonable
tolerance levels. Execution is terminated with a condition code.
 TOLER – Input is not balanced but is within reasonable
tolerance levels. Execution is terminated with a condition code.
 ABEND – Execution is terminated with a user abend code.

COD Any valid condition code (or user abend code in case of result
ABEND) between 0000 and 4000. Optional.

General Information
Control-M/Analyzer uses the DO TERMINAT statement to control work flow within a job based on whether
input is in or out of balance. Control-M/Analyzer sends the condition code or user abend code back to the
job itself, that then either continues executing or terminates based on the specified condition code or user
abend code. See your JCL manual for information about the JCL COND parameter.

428
Control-M/Analyzer User Guide

If the execution of a rule definition ends normally (no errors occur) and a DO TERMINAT statement is not
specified, the rule will terminate with the default status specified in the DEFSTAT installation parameter
and the return code specified in the DEFCODE installation parameter. For details, refer to the
Control-M/Analyzer chapter of the INCONTROL for z/OS Installation Guide.
Control-M/Analyzer Database variables are committed (according to the method specified in the DO
COMMIT statement) when the rule terminates. Termination occurs under the following conditions:
 If the rule was called by a job step, commitment occurs when the rule terminates.
 If the rule was called by another rule (by the DO RULE statement), commitment occurs when the
calling rule terminates.
After termination, processing flow control returns to the entity that invoked the called rule; for example,
to the next job step (in the job that called the rule) or to the calling rule.

Example
The rule terminates NOTOK with a condition code of 0055 if the sum computed is more than
1,000,000.00. Otherwise, the rule terminates OK with a condition code of 0.
Figure 228 DO TERMINAT Statement Example
LIBRARY : CTB.PROD.RULES RULE : RULCURR
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
IF SUM > 1000000.00 C
DO SHOUT TO TSO-M18 URGENCY R
= PLEASE CHECK CURRENCY FILE; SUM COMPUTED IS %%SUM
DO REMARK = SUM IS OVER 1000000.00 SUM=%%SUM
DO COND = NOTOK-%%SYSJOBNAME 0704 +
DO TERMINAT = NOTOK COD 0055
DO
ELSE
DO REMARK = SUM IS NOT OVER 1000000.00 SUM=%%SUM
DO TERMINAT = OK COD 0000
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 13.52.20

429
Control-M/Analyzer User Guide

EXECUTE: Data Selection Statement


Specifies the name of the current EXECUTE block, and determines if the current EXECUTE block should be
executed based on conditional UPON criteria.
Figure 229 EXECUTE Statement Format

Mandatory. The EXECUTE statement marks the beginning of an EXECUTE block. The statements after the
EXECUTE statement (but before another EXECUTE statement) constitute the EXECUTE block. An unlimited
number of EXECUTE blocks can be included in a rule. For additional information see EXECUTE Block
Structure Overview (on page 351).
Table 249 EXECUTE Statement Fields

Field Description

UPON This parameter specifies criteria that determine if the current


EXECUTE block is executed. These criteria are specified as a
Control-M/Analyzer expression. Expression syntax is discussed in
Chapter 4, "Expressions and Functions."
A maximum of 11 lines (of 49 characters each) can be used to
specify UPON criteria. Specify Y (Yes), in the C (Continue?) field to
open another line for the continuation of the UPON parameter. Type
N (No) in the C (Continue?) field to close the UPON parameter.

General Information
The UPON parameter determines whether the EXECUTE block is performed. If the expression specified by
UPON evaluates to true, the block is processed. Conversely, if the expression evaluates to false, the entire
block is skipped.

430
Control-M/Analyzer User Guide

The EXECUTE block name is used as a point of reference. A DO BLOCK statement causes
Control-M/Analyzer to branch (skip) directly to the specified EXECUTE block name and executes the
subsequent statements. Control-M/Analyzer then returns to the point after the initial DO BLOCK
statement.
Note: For more information about the EXECUTE block name and branching within a rule see DO BLOCK:
Automated Balancing Statement (on page 368).

Examples
Example 1
BMC recommends that EXECUTE block names (that are specified by statement EXECUTE) represent the
purpose of the block. In this example, the first EXECUTE block is called INIT because it performs
initialization procedures. The second EXECUTE block is called INPUT because it extracts data from a file as
input to Control-M/Analyzer variables. These variables are checked in subsequent EXECUTE blocks of the
rule.
Figure 230 DO EXECUTE Statement – Example 1
LIBRARY : CTB.PROD.RULES RULE : RULEMP
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE INIT UPON C
ON DATA
ALWAYS
DO SET = CNTR=0 C
DO SET = ERR=0 C
DO PRINT = UNREASONABLE SICK/VACATION DAYS F C
DO PRINT = ================================= F C
DO PRINT = +--+---------------+------+—----+ F C
DO PRINT = | | NAME | SICK | VAC | F C
DO PRINT = +--+---------------+------+-----+ F C
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE INPUT UPON C
ON FILE FILENAME CTB.PROD.EMPREP
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 001 - 060 COL 015 - 015 TYPE STOP AND/OR
STRING = #
DO EXTRACT = NAME
PLEASE FILL IN RULE DEFINITION. 10.31.08

Example 2
EXECUTE block INPUT extracts information from each line in a file and executes EXECUTE block CHECK to
check each line. EXECUTE block CHECK is located at the end of the rule. If the current line is exceptional
(for example, the employee has taken more than 90 sick days or more than 30 vacation days), a line is
printed to the Control-M/Analyzer Rule Activity report.

431
Control-M/Analyzer User Guide

Figure 231 DO EXECUTE Statement – Example 1


LIBRARY : CTB.PROD.RULES RULE : CHKEMP1
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE INPUT UPON C
ON FILE FILENAME CTB.PROD.EMPREP
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 001 - 060 COL 015 - 015 TYPE STOP AND/OR
STRING = #
DO EXTRACT = NAME
LEVEL 0 LINE +000 COL -002 - +013 PROCESS TYP
DO EXTRACT = SICK
LEVEL 0 LINE +000 COL +087 - +088 PROCESS TYP
DO EXTRACT = VAC
LEVEL 0 LINE +000 COL +093 - +094 PROCESS TYP
DO BLOCK = CHECK ARG NAME,SICK,VAC C
DO
WHEN LINE - COL - TYPE STOP AND/OR
STRING =
DO
===========================================================================
.
.
.
===========================================================================
EXECUTE CHECK UPON BARG02 > 90 | BARG03 > 30 C
ON DATA
ALWAYS
DO PRINT = | |%%BARG01| %%BARG02 | %%BARG03 | F C
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

432
Control-M/Analyzer User Guide

GROUP: Data Selection Statement


Specifies the name of the group.
Figure 232 GROUP Statement Format

Optional. The GROUP parameter specifies a group name of 1 to 20 characters. Only trailing blanks are
allowed.

General Information
The GROUP parameter is used for convenient handling of rules. It enables the retrieval of information
about a specific rule, usually through the Online Tracking and Control facility or through the Reporting
facility.
The group name appears in all important messages relating to the rule.
Using groups, complete systems may be tested as a unit, for simulation purposes.
When a rule executes, the default group name specified by the GROUP parameter is the group with which
Database variables are accessed.
During rule execution, the group name specification is checked for existence in the Control-M/Analyzer
Database Variable file. Several invocation methods exist that determine the group name under that a rule
executes:
 Direct invocation by a job step or program
The group specified by the job step or program is used. If no group is specified by the job step or
program, the GROUP specification in the rule definition is used.
 Invocation by mission
GROUP receives its value from the mission definition. In this case, the group name specified by the
mission definition overrides the group name specified by the rule definition.

433
Control-M/Analyzer User Guide

 Invocation by other INCONTROL products


When the rule is called by statement DO CTBRULE in Control-M or Control-D, GROUP receives its
value from the Control-M job scheduling definition or the Control-D decollating mission. In this case,
the group name specified by the job or decollating definition overrides the group name specified by
the rule definition.
A detailed explanation of all GROUP features is provided in Introduction (on page 19).

Example
Figure 233 GROUP Statement Example
LIBRARY : CTB.PROD.RULES RULE : CHECKCUR
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M55 GROUP CURRENCY
UPDATED 08/08/00 - 09:18:35 BY M55A
DESC CHECK BALANCING OF BANK'S FOREIGN CURRENCY INVESTM
OPTIONS
===========================================================================
EXECUTE CHECK UPON C
ON SYSOUT PROCST PGMST DDNAME REPORT JOBNM
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 020 - 030 COL 001 - 132 STOP AND/OR
STRING = NOT BALANCED
DO SHOUT TO OPER URGENCY R
= FOREIGN CURRENCY REPORT NOT BALANCED !!!
DO TERMINAT = NOTOK COD 1001
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 09.25.30

434
Control-M/Analyzer User Guide

IF: Data Selection Statement


Provides conditional performance of a processing unit using Boolean logic.
Figure 234 IF Statement Format

Optional. IF specifies criteria that determine whether subsequent Automated Balancing statements are
executed.
When ON DATA is specified and Enter is pressed, the IF statement can be specified in the area that is
opened on the screen. When IF (or its abbreviation I) is specified and Enter is pressed, the following
fields are displayed:
Table 250 IF Statement Fields

Field Description

LABEL Name associated with the subsequent DO statements. LABEL can


have a maximum of 8 characters. Label names must be unique
within a rule definition.

expression Criteria that determine if subsequent DO statements are processed.


Control-M/Analyzer expressions are discussed in depth in Chapter 4,
"Expressions and Functions".
After specifying expression and pressing Enter, an area is opened
for specification of an ALWAYS statement, another IF statement, or
an ELSE statement.

DO Specification of Automated Balancing statements. See "Automated


Balancing Statements" in this chapter for summary information
about each DO statement.
When an IF conditional expression evaluates to true, the DO
statements following that IF are performed. When an IF conditional
expression evaluates to false, the DO statements following that IF
are skipped.

435
Control-M/Analyzer User Guide

Field Description

ELSE When ELSE is specified, the DO statements following that ELSE are
performed only when the preceding IF evaluates to false.
An area for specification of the ELSE parameter is opened on the
Rule Definition screen after expression is specified and Enter is
pressed. Type ELSE (or its abbreviation E) in this area and press
Enter. When Enter is pressed, another area is opened for
specification of the ALWAYS and IF parameters, and a field appears
for specification of Automated Balancing statements.

When set to Y (Yes), the C (Continue?) field provides additional space for specifying the IF expression. A
maximum of 9 lines can be opened. Specifying N (No) in the C (Continue?) field closes the IF expression.

General Information
Available only when ON DATA is specified.
When IF evaluates to true, the DO statements after the IF are executed. If that IF is matched by a
corresponding ELSE, the DO statements after the ELSE are not executed.
When IF evaluates to false, the DO statements after that IF are skipped. If that IF is matched by a
corresponding ELSE, the DO statements after that ELSE are executed.
The LABEL parameter is used as a reference point for flow processing (branching). LABEL is used in
conjunction with statement DO GOTO. When specified, DO GOTO passes processing control to the
matching LABEL. See statement DO GOTO in this chapter for additional information.

Examples
Example 1
EXECUTE block BAL determines if a stock order should be issued for items that belong to group 781.
The current on-hand quantity of items in this group was calculated in previous EXECUTE blocks. Using the
IF parameter, the current on-hand quantity amount can be compared to 1000 to determine if a stock
order must be issued.

436
Control-M/Analyzer User Guide

Figure 235 IF Statement – Example 1


LIBRARY : CTB.PROD.RULES RULE : RULINV
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE BAL UPON C
ON DATA
ALWAYS
DO PRINT = TOTAL QUANTITY FOR FINAL ASSEMBLY SHOP F C
DO PRINT = GROUP 781 IS &&QTY F C
DO
IF QTY < 1000 C
DO SHOUT TO U-M18 URGENCY R
= ORDER NEW STOCK FOR GROUP 781 (QTY=&&QTY)
DO REMARK = REQUEST ORDER OF STOCK FOR GROUP 781
DO TERMINAT = NOTOK COD 0004
DO
ELSE
DO REMARK = STOCK OF GROUP 781 IS OK
DO TERMINAT = OK COD 0000
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
PLEASE FILL IN RULE DEFINITION. 18.49.42

Example 2
In EXECUTE block PROCESS, the current total value (DB_CURRENT_TOTAL) is compared to the same
value from last month's report (DB_CURRENT_TOTAL@G01). This example represents a "run-to-run
check." To verify that the current total value is reasonable, the two values are compared; Their difference
should not be greater than 10,000.
Figure 236 IF Statement – Example 2
LIBRARY : CTB.PROD.RULES RULE : RUNCHK
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE PROCESS UPON C
ON DATA
IF (DB_CURRENT_TOTAL - DB_CURRENT_TOTAL.@G01) > 10000 C
DO SHOUT TO OPER URGENCY R
= -- ADMIN REPORT IS OUT OF BALANCE --- CALL 714-5678 - JOHN
DO TERMINAT = NOTOK COD 1501
DO
ELSE
DO TERMINAT = OK COD 0000
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 19.02.08

437
Control-M/Analyzer User Guide

ON Statement: Data Selection Statement


Defines the data source that the rule processes.
Figure 237 ON Statement Format

Mandatory. Type one of the data source options – CLASS, DB2, DDNAME, DSN, FILE, PAGE, SYSDATA,
SYSOUT, VSAM, DATA – in the ON field and press Enter. If the selected option is valid,
Control-M/Analyzer displays the relevant parameters.
Note: It is usually not necessary to enter the full name of the data source option. The shortest unique
abbreviation of the option is sufficient.
Each ON statement is summarized below and discussed in detail on the following pages.
Table 251 ON STATEMENT Fields

Field Description

ON CLASS Processes all outputs of jobs belonging to the specified class,


destination, external writer, and form. Control-M/Analyzer receives
the output characteristics from the system.

ON COMPARE Compares two data sources.

ON DATA Processes Control-M/Analyzer variables. ON DATA is unique in that


it provides conditional execution through the IF statement and
unconditional execution through the ALWAYS statement. The WHEN
statement cannot be specified.

ON DB2 Processes data from DB2 tables using the dynamic SQL facility.

ON DDNAME Processes the sequential datasets referenced by the specified


DD statement in the current step (for example, the step from which
the Control-M/Analyzer Runtime Environment was invoked).

438
Control-M/Analyzer User Guide

Field Description

ON DSN For Control-D users: Processes one or more Compressed Dataset


Access Method (CDAM) files. CDAM selection criteria must be
specified.

ON FILE Processes a sequential dataset. Control-M/Analyzer receives the


characteristics of the sequential dataset from the system. The file
name must represent a physical sequential (PS) dataset, or a
partitioned dataset (PDS), with member name in parentheses.

ON PAGE For Control-D users: Processes pages passed to the


Control-M/Analyzer rule when Control-M/Analyzer is invoked by the
Control-D monitor (by statement DO CTBRULE in a report
decollating mission).

ON SYSDATA For Control-M and Control-M/Restart users: Processes the three job
sysout datasets referred to as SYSDATA.a SYSDATA is available to
the current job when Control-M/Analyzer is invoked by the
Control-M monitor (by statement DO CTBRULE in a job scheduling
definition).

ON SYSOUT Processes sysouts referenced by the specified DD statement.


Control-M/Analyzer receives the output characteristics from the
system. ON SYSOUT is only available under JES2.

ON VSAM Processes VSAM file records using user-specified keys, or record


addresses (RBAs).

General Information
Each EXECUTE block must contain only one ON statement. An ON statement is comprised of the ON
parameter and Data Identification statements. Different Data Identification statements are displayed
depending on which ON statement is specified.
All ON statements (except ON DATA) display MODE, LINECT, and DATASTAMP parameters, plus Data
Identification statement WHEN, which provides conditional execution of subsequent statements based on
Data Identification criteria.
See Datastamp Calculation (on page 442) for information about creating unique datastamps. For
information about using datastamps, seeDATASTAMP: Functions (on page 286).
The ON DATA statement does not display MODE, LINECT, DATASTAMP, or WHEN parameters. Instead,
conditional or unconditional execution of subsequent statements is provided using IF or ALWAYS Data
Identification statements. For more information, see IF: Data Selection Statement (on page 435), and
ALWAYS: Data Identification Statement (on page 358).

439
Control-M/Analyzer User Guide

Examples
Example 1
EXECUTE block INPUT processes sequential file CTB.PROD.EMPREP.
Figure 238 ON Statement – Example 1
LIBRARY : CTB.PROD.RULES RULE : RULEMP
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE INPUT UPON C
ON FILE FILENAME CTB.PROD.EMPREP
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 001 - 060 COL 015 - 015 STOP AND/OR
STRING = #
DO EXTRACT = NAME
LEVEL 0 LINE +000 COL -002 - +013 PROCESS TYP
DO EXTRACT = SICK
LEVEL 0 LINE +000 COL +087 - +088 PROCESS TYP
DO EXTRACT = VAC
LEVEL 0 LINE +000 COL +093 - +094 PROCESS TYP
DO BLOCK = CHECK ARG NAME,SICK,VAC C
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE FIN UPON C
ON DATA
PLEASE FILL IN RULE DEFINITION. 16.00.22

440
Control-M/Analyzer User Guide

Example 2
Statement ON CLASS in the first EXECUTE block identifies the output of class X as the source of the
information to be balanced. This information is compared with corresponding information from the
previous run by statement ON DATA in EXECUTE block PROCESS.
Figure 239 ON Statement – Example 2
LIBRARY : CTB.PROD.RULES RULE : RUNCHK
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE EXTRACT UPON C
ON CLASS = X EXTWTR DEST FORM
MODE PG LINECT 0060
WHEN LINE 004 - 020 COL 001 - 080 STOP AND/OR
STRING = TOTALS:
DO EXTRACT = DB_CURRENT_TOTAL
LEVEL LINE +000 COL +002 - +008 PROCESS TYP
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE PROCESS UPON C
ON DATA
LABEL:
IF (DB_CURRENT_TOTAL - DB_CURRENT_TOTAL@G01)> 10000 C
DO SHOUT TO OPER URGENCY R
= — REPORT IS OUT OF BALANCE —- CALL 714-5678 - JOHN SMITH
DO TERMINAT = NOTOK COD 1501
DO
ELSE
DO TERMINAT = OK COD 0000
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 16.18.5

441
Control-M/Analyzer User Guide

Datastamp Calculation
Datastamps are unique identifiers that can be assigned to files whenever any ON statement (other than
ON DATA) is executed.
Calculating Datastamps
 As a default, a Datastamp is not calculated. Performance is significantly improved when Datastamp
processing is not performed. To avoid Datastamp processing, leave the DATASTAMP parameter blank
in the ON statement that identifies the file that does not require a datastamp. See "Example 1" below
for a sample rule that does not perform Datastamp processing.
 When Datastamp processing is necessary, the datastamp can be calculated more efficiently by setting
the DATASTAMP parameter to 2 in the ON statement that identifies the file that needs to receive a
unique identifier. See "Example 2" below for a sample rule specifying DATASTAMP 2.
 Datastamp processing can also be performed according to the original method for compatibility
purposes. To request original Datastamp processing, set the DATASTAMP parameter to 1 in the ON
statement that identifies the file that needs to receive a unique identifier. See "Example 3" below for a
sample rule specifying DATASTAMP 1.
Example 1
A Datastamp is not calculated for ON DDNAME because the DATASTAMP parameter is blank in the ON
statement.
Figure 240 ON Statement DATASTAMP Parameter – Example 1
LIBRARY : CTBP.PROD.RULES RULE : CALCSTAM
COMMAND ===> SCROLL===> CRSR
+-------------------------------------------------------------------------------+
OWNER N43 GROUP ACCOUNTING
UPDATED 08/08/00 - 13:25:57 BY M43
DESC
OPTIONS
==============================================================================
EXECUTE NOCOMPAR UPON C
ON DDNAME DDNAME ACCTENTR
MODE DS LINECT DATASTAMP 2
WHEN LINE 010 - 010 COL 015 - 025 STOP AND/OR
STRING = TOTAL:
DO EXTRACT = MTOTAL
LEVEL LINE +000 COL 0027 - 0040 PROCESS BKUNPK TYP
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE UPON C
ON
PLEASE FILL IN RULE DEFINITION. 13.32.52

442
Control-M/Analyzer User Guide

Example 2
A unique DATASTAMP is calculated by the new method because DATASTAMP 2 is specified in the ON
statement.
Figure 241 ON Statement DATASTAMP Parameter – Example 2
LIBRARY : CTBP.PROD.RULES RULE : ORIGINAL
COMMAND ===> SCROLL===> CRSR
+------------------------------------------------------------------------------+
OWNER N43 GROUP ACCOUNTING
UPDATED 08/08/00 - 13:25:57 BY M43
DESC
OPTIONS
=============================================================================
EXECUTE DOCOMPAR UPON C
ON DDNAME DDNAME ACCTENTR
MODE DS LINECT DATASTAMP 2 2
WHEN LINE 010 - 010 COL 015 - 025 STOP AND/OR
STRING = TOTAL:
DO EXTRACT = MTOTAL
LEVEL LINE +000 COL 0027 - 0040 PROCESS BKUNPK TYP
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===============================================================================
EXECUTE SAMEFILE UPON C
ON DATA
IF DATASTAMP(DOCOMPAR)=DB_LASTCOMPARE C
DO PRINT = THE FILES ARE THE SAME F C
DO
ELSE
DO PRINT = THE FILES ARE NOT THE SAME F C
DO
(ENTER "ALWAYS", "IF")
===============================================================================
EXECUTE UPON C
ON
PLEASE FILL IN RULE DEFINITION. 13.32.52

443
Control-M/Analyzer User Guide

Example 3
A unique DATASTAMP is calculated by the original method because DATASTAMP 1 is specified in the ON
statement.
Figure 242 ON Statement DATASTAMP Parameter – Example 3
LIBRARY : CTBP.PROD.RULES RULE : ORIGINAL
COMMAND ===> SCROLL===> CRSR
+------------------------------------------------------------------------------+
OWNER N43 GROUP ACCOUNTING
UPDATED 08/08/00 - 13:25:57 BY M43
DESC
OPTIONS
================================================================================
EXECUTE DOCOMPAR UPON C
ON DDNAME DDNAME ACCTENTR
MODE DS LINECT DATASTAMP 1
WHEN LINE 010 - 010 COL 015 - 025 STOP AND/OR
STRING = TOTAL:
DO EXTRACT = MTOTAL
LEVEL LINE +000 COL 0027 - 0040 PROCESS BKUNPK TYP
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===============================================================================
EXECUTE SAMEFILE UPON C
ON DATA
IF DATASTAMP(DOCOMPAR)=DB_LASTCOMPARE C
DO PRINT = THE FILES ARE THE SAME F C
DO
ELSE
DO PRINT = THE FILES ARE NOT THE SAME F C
DO
(ENTER "ALWAYS", "IF")
===============================================================================
EXECUTE UPON C
ON
PLEASE FILL IN RULE DEFINITION. 13.32.52

444
Control-M/Analyzer User Guide

ON CLASS: Data Selection Statement


Processes all outputs of jobs belonging to any or all of the specified class, destination, external writer, or
form.
Figure 243 ON CLASS Statement Format

Type the word CLASS (or its abbreviation CL) to the right of the ON in the Rule Definition screen. When
Enter is pressed, the = prompt and the following fields are displayed:

445
Control-M/Analyzer User Guide

Table 252 ON CLASS Statement Fields

Field Description

class Name of the class of specified sysouts. The class value can have a
maximum of 8 characters. Mandatory.

EXTWTR Name of an external writer to which the reports are written.


EXTWTR can have a maximum of 8 characters. Optional.

DEST Name of a printing destination for reports. DEST can have a


maximum of 8 characters. Optional.

FORM Name of a printing form for reports. FORM can have a maximum of
4 characters. Optional.

MODE Determines the starting point for calculating statement WHEN line
and column specifications. See statement WHEN in this chapter.
Optional. Available modes are:
 DS (Dataset) — Line and column values are based on the start
of the dataset.
 PG (Page) — Line and column values are based on the start of
the page. Default.

LINECT Specifies number of lines per printed page. Optional. If not


specified, the default is 60.

DATASTAMP Determines whether a unique datastamp is calculated and assigned


to the data sources.
 blank — Datastamp is not generated. Default.
 1 — Datastamp is calculated using the original algorithm to
ensure compatibility with prior versions of Control-M/Analyzer.
 2 — A Datastamp is calculated using the newer, more efficient
algorithm.
For more information see Datastamp Calculation (on page 442).

General Information
ON CLASS processes outputs (sysouts) of previous steps in the current job. For Control-M/Analyzer to
process these sysouts, the output must be in HELD state and FREE=CLOSE must be specified in the DD
statement that created the output.
See the Control-M/Analyzer chapter of the INCONTROL for z/OS Installation Guide for a discussion of
HELD sysout processing under JES3.

446
Control-M/Analyzer User Guide

ON CLASS selects all outputs with a class that matches one of the specified classes. A maximum of eight
classes may be specified by listing them one after the other.
ON CLASS accepts additional subparameters that further limit the selection of sysouts from the specified
classes. Valid subparameters are shown in Table 253.
Table 253 ON CLASS Additional Subparameters

Subparameter Description

EXTWTR Only sysouts from the specified EXTWTR of a specified CLASS are
processed.

DEST Only sysouts for the specified DEST of a specified CLASS are
processed.

FORM Only sysouts for the specified FORM of a specified CLASS are
processed.

Control-M/Analyzer AutoEdit and Local variables can be embedded in the CLASS, EXTWTR, DEST, and
FORM parameters. The variables are resolved (replaced) at time of rule execution. For additional
information on AutoEdit processing, see Chapter 3, "Control-M/Analyzer Variables."

Example
EXECUTE block EXTRACT processes reports in class X. Information is extracted from the report and
compared with data from a previous report in EXECUTE block PROCESS.
Figure 244 ON CLASS Statement Example
LIBRARY : CTB.PROD.RULES RULE : RUNCHK
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE EXTRACT UPON C
ON CLASS = X EXTWTR DEST FORM
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 004 - 020 COL 001 - 080 STOP AND/OR
STRING = TOTALS:
DO EXTRACT = DB_CURRENT_TOTAL
LEVEL 0 LINE +000 COL +002 - +008 PROCESS TYP
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE PROCESS UPON C
ON DATA
IF (DB_CURRENT_TOTAL - DB_CURRENT_TOTAL@G01)> 10000 C
DO SHOUT TO OPER URGENCY R
= -- REPORT IS OUT OF BALANCE —- CALL 714-5678 - JOHN SMITH
DO TERMINAT = NOTOK COD 1501
DO
PLEASE FILL IN RULE DEFINITION. 15.11.23

447
Control-M/Analyzer User Guide

ON COMPARE: Data Selection Parameter


Compares two data sources involved in the reconciliation process. Comparison is performed within one
Control-M/Analyzer rule.
Figure 245 ON COMPARE Format

Type the word COMPARE (or its abbreviation CO) after the ON in the Rule Definition screen, and press
Enter. The following fields are displayed:
Table 254 ON COMPARE Statement Fields

Field Description

SOURCE1 Specification for the first data source. Mandatory. The value Y (yes)
must be specified for one and only one of the FILE, SYSOUT, or DD
subparameters.

FILE Valid values are:


 Y (Yes)
 N (No). Default.
If Y is specified, FILENAME is displayed and a valid
filename must be specified.
FILENAME – Name of the sequential dataset used as
the data source. Maximum 44 characters.
Mandatory.

448
Control-M/Analyzer User Guide

Field Description

SYSOUT Valid values are:


 Y (Yes)
 N (No). Default.
If Y is specified, the following additional
subparameters are displayed. A value, up to 8
characters, must be specified for at least one of
these subparameters.
 PROCST – Name of procedure step whose
SYSOUT is used as the data source.
 PGMST – Name of the program step whose
SYSOUT is used as the data source.
 DDNAME – Name of the DD statement that
references the file used as the data source.
 JOBNM – Name of the job that is used as the
data source.

DD Valid values are:


 Y (Yes)
 N (No). Default.
If Y is specified, the DDNAME subparameter is
displayed, and a value for it must be specified.
DDNAME – Name of the DD statement that
references the file used as the data source.

PROCESS Indicates whether each line is subject to modification before being sent
to the Differences algorithm (described below). Valid values are:
 Y (Yes)
 N (No). Default.
If Y is specified, the BUILTIN and USERBLOCK subparameters are
displayed and a valid built-in process or a valid user block name must
be specified.

449
Control-M/Analyzer User Guide

Field Description

BUILTIN Name of a built-in process to be performed.


Maximum 8 characters. Currently, the only valid
value is BMSUBST, a process that modifies strings in
input lines, based on specified masks.
If built-in process BMSUBST is specified, the
SUBSTFROM and SUBSTTO subparameters are
displayed.
 SUBSTFROM–Mask for the string that is input to
the process, such as ‘??/??/??’. Maximum 20
characters. Mandatory.
 SUBSTTO–Mask for the string that is output
from the process, such as ‘??/??/19??’.
Maximum 20 characters. Mandatory.

USERBLOCK Name of a user-defined block to be performed. The


block must be defined elsewhere in the same rule.
Maximum 8 characters.

SOURCE2 Specification for the second data source. Mandatory. The same
subparameter descriptions apply to both SOURCE1 and SOURCE2. See
the descriptions above for information about SOURCE2 subparameters.

MODE Starting point for line and column values. Optional. Valid values are:
 DS – Line and column values are calculated from the beginning of
the dataset.
 PG – Line and column values are calculated from the beginning of
the page.
If a value is not specified, the value DS is automatically inserted.

LINECT Number of lines per printed page. Optional. Minimum: 1. Default: 60.

DATASTAMP Determines whether a unique datastamp is calculated and assigned to


the data sources. For more information, see Datastamp Calculation (on
page 442). Valid values are:
 blank – Datastamp is not generated. Default.
 1 – Datastamp is calculated using the original algorithm to ensure
compatibility with prior versions of Control-M/Analyzer.
 2 – Datastamp is calculated using the newer, more efficient
algorithm.

450
Control-M/Analyzer User Guide

General Information
Control-M/Analyzer reads the data sources identified in SOURCE1 and SOURCE2, line by line, and sends
each line to the ON COMPARE Differences algorithm. However, if a Process has been specified for a data
source, the input line is processed accordingly before it is sent to the Differences algorithm (for
example, the Process may change the line using substitute masks, function SUBSTR, string concatenation,
and/or some other mechanism). In this case, the modified (for example, processed) input line is sent to
the Differences algorithm.
After Control-M/Analyzer has sent all input lines to the Differences algorithm, the Differences algorithm
searches for the longest identical sequence of lines in both files to synchronize changes. The algorithm is
implemented recursively until all identical lines have been found.
For each remaining (non-identical) line, Control-M/Analyzer performs the WHEN block (see diagram
below). In the WHEN block, the SYSCURLINE system variable holds the current line and the logical DIFF
line indicates the following information:
Table 255 Contents of DIFF Line After ON COMPARE Processing

Datum Description

LINE STATUS Status of the current line. Possible values are:

INSERTED Line exists in source 1 but not in source


2.

DELETED Line exists in source 2 but not in source


1.

REPLACED Line is not identical in sources 1 and 2.

SOURCE1 LINE NUMBER / Line number of the current line from data source 1, or line
RANGE range of the replaced lines.

SOURCE2 LINE NUMBER / Line number of the current line from data source 2, or line
RANGE range of the replaced lines.

The ON COMPARE block cannot contain ON, DO TERMINAT, DO RULE, or DO EXIT statement types:.
The following source restrictions are applicable:
 The SYSOUT parameter can be used only once in an ON COMPARE statement (for example, to specify
SOURCE1 or SOURCE2, but not both).
 The SYSOUT parameter can only specify a sysout that was closed before the current step began.
 The FILE and DD Parameters can specify a file that was created in the current step if the file is closed
before the ON COMPARE block is invoked.
Based on these source restrictions, sysouts can be compared by the following methods:

451
Control-M/Analyzer User Guide

 To compare the sysout of the current job with another sysout, specify the current sysout by the DD
parameter and the other sysout by the SYSOUT parameter.
 To compare two sysouts when neither is of the current job, copy one sysout to a file, specify that file
using the FILE parameter, and specify the other sysout using the SYSOUT parameter.

MSUBSTMASK Function
MSUBSTMASK is a function that can execute multiple substitution commands contained in the file
referenced by the DD statement specified as its first argument. The format of the MSUBSTMASK function
is:
MSUBSTMASK (ddname,long-string-variable)

where long-string-variable contains the string that is currently being processed. The file referenced by
ddname can, for example, contain the following line:
SUBSTFROM '(???) ???-????' SUBSTTO '???-???-????' EOS

where EOS, which means "end of substitution," is mandatory at the end of each substitution statement.

Example
This example illustrates how function MSUBSTMASK can be used to modify strings in a USERBLOCK
process (SUBSDATE) by removing the first 2 digits in the year field.
Figure 246 ON COMPARE Statement Example
EXECUTE 'RECONCIL'
ON_COMPARE
SOURCE1
DD 'DDBEFORE' PROCESS USERBLOCK 'SUBSDATE'
SOURCE2
DD 'DD#AFTER'
WHEN FLINE 1 TLINE 80 FCOL 1 TCOL 80 SEARCH '.AL.'
DO EXTRACT 'DIFFDESC' LEVEL 0 LINE +0 FCOL 1 TCOL 80
DO PRINT DATA '%%DIFFDESC'
EXECUTE 'END'
ON_DATA
ALWAYS
DO TERMINATE RESULT OK USER-CODE 0
EXECUTE 'SUBSDATE'
ON_DATA
ALWAYS
DO SET 'RC' EVAL 'MSUBSTMASK(''DDSUBST'',SYSCURLINE)'

SYSCURLINE is the long-string variable that contains the string that is currently being processed.
DDSUBST is enclosed by double quotes because the MSUBSTMASK function is enclosed by single quotes
inside a DO SET statement. DDSUBST contains the following lines:
//DDSUBST DD *
SUBSTFROM '??/??/19??' SUBSTTO '??/??/??' EOS
SUBSTFROM '??/??/20??' SUBSTTO '??/??/??' EOS
/*

For an example of how function MSUBSTMASK can be used for converting currencies, see D Euro
Support (on page 678).

452
Control-M/Analyzer User Guide

ON COMPARE Work Flow


The work flow of the ON COMPARE process is illustrated below:
Figure 247 ON COMPARE Work Flow

Logical DIFF line is the output of the DIFF algorithm. The line format is:

453
Control-M/Analyzer User Guide

{I | D | R},{LINE# | RANGE#} SOURCE1={line | range},SOURCE2={line | range}

where:
 I/D/R indicates INSERTED/DELETED/REPLACED lines
 SOURCE1 line/range is the current line number or range of lines, in source1
 SOURCE2 line/range is the current line number or range of lines, in source2

Example Outputs
I,LINE#SOURCE1=0000024,LINE#SOURCE2=0000023

One line was added in SOURCE1 after line 23.


D,LINE#SOURCE1=0000024,LINE#SOURCE2=0000011

Line 24 in SOURCE1, that corresponded to line 11 in SOURCE2, was deleted.


R,RANGE#SOURCE1=(0000006,0000008),RANGE#SOURCE2=(0000006,0000009)

Lines 6 through 9 in SOURCE2 correspond to lines 6 through 8 in SOURCE1.


Example 1
Use built-in process BMSUBST to substitute dates only, and compare the rest of the line as is. Print out
only lines that were changed or added to SOURCE2.
Table 256 ON COMPARE Input Data – Example 1
DD#BEFORE:
GLOBAL BANK INC. DATE: 22/09/00
******************
* LOAN INTEREST *
******************

OPEN DATE DUE DATE INTEREST UPDATED ON


========== ========== ======== ==========
08/03/95 08/03/96 5.32 % 22/02/95
09/12/95 09/12/96 5.13 % 24/11/95
11/12/95 11/12/96 5.60 % 24/11/95
05/02/96 05/02/97 5.70 % 02/02/94
06/06/96 06/06/97 5.26 % 01/01/96
10/08/96 10/08/97 5.78 % 01/01/96
END OF REPORT
DD#AFTER:
GLOBAL BANK INC. DATE: 22/09/2000
******************
* LOAN INTEREST *
******************

OPEN DATE DUE DATE INTEREST UPDATED ON


========== ========== ======== ==========
08/03/1995 08/03/1990 5.32 % 22/02/1995
09/12/1995 09/12/1996 5.13 % 24/11/1900
11/12/1995 11/12/1996 5.60 % 24/11/1995
05/02/1996 05/02/1997 5.70 % 02/02/1994
06/06/1996 06/06/1997 5.26 % 01/01/1996@@@
10/08/1996 10/08/1997 5.78 % 01/01/1996

END OF REPORT

454
Control-M/Analyzer User Guide

Figure 248 ON COMPARE Testing Rule – Example 1


EXECUTE 'RECONCIL'
ON_COMPARE
SOURCE1
DD 'DDBEFORE' PROCESS BUILTIN 'BMSUBST'
SUBSTFROM '??/??/?? ' SUBSTTO '??/??/19??'
SOURCE2
DD 'DD#AFTER'
ON_PARM MODE DS LINECT 80
WHEN FLINE 1 TLINE 999 FCOL 1 TCOL 1 SEARCH '.AL.'
DO EXTRACT 'LINE' LEVEL 0 LINE +0 FCOL 1 TCOL 80
DO BLOCK 'CHKDATE'
EXECUTE ’END’
ON_DATA
ALWAYS
DO TERMINATE RESULT OK USER-CODE 0
EXECUTE 'CHKDATE'
ON_DATA
IF 'SUBSTR(1,1,LINE) = ''I'''
DO SET 'DIFFLINE' EVAL 'SYSCURLINE'
DO PRINT DATA 'NOT OK ===>%%DIFFLINE'

Figure 249 ON COMPARE Output – Example 1


These output lines refer to those lines in the DD#AFTER report of Table 256 that contain bolded items.
NOT OK ===> 08/03/1995 08/03/1900 5.32 % 22/02/1995
NOT OK ===> 09/12/1995 09/12/1996 5.13 % 24/11/1900
NOT OK===> 06/06/1996 06/06/1997 5.26 % 01/01/1996@@@

455
Control-M/Analyzer User Guide

Example 2
Substitute dates in specific columns with a user block. Compare the rest of the line as is.
Table 257 ON COMPARE Input Data – Example 2
DO BEFORE
GLOBAL BANK INC.
PAGE: 1
*******************************
C U S T O M E R L I S T I N G
*******************************

ACCOUNT OPEN CLOSE DEPOSIT


NO. DATE DATE AMOUNT ($)
======== ==== ===== ==========
12-56-82 02-04-93 02-04-96 3,000.00
12-56-45 09-08-95 09-08-99 7,500.00
12-56-36 01-02-98 01-02-02 1,000.00
22-68-25 03-06-94 03-06-99 10,000.00
22-68-75 09-07-97 09-07-99 8,000.00
22-56-57 02-05-94 02-05-97 5,000.00
22-56-36 09-09-96 09-09-99 9,500.00
12-56-25 02-04-93 02-04-96 3,000.00
12-66-83 09-08-95 09-08-99 7,500.00
12-66-98 01-02-98 01-22-03 2,000.00
22-68-75 03-06-94 03-06-99 10,000.00
22-68-56 09-07-97 09-07-01 8,000.00
22-76-54 02-05-94 12-05-97 5,000.00
22-76-23 09-09-96 09-09-99 9,500.00
DO AFTER
GLOBAL BANK INC.
PAGE: 1
*******************************
C U S T O M E R L I S T I N G
*******************************

ACCOUNT OPEN CLOSE DEPOSIT


NO. DATE DATE AMOUNT ($)
======== ==== ===== ==========
12-56-82 02-04-1993 02-04-1996 3,000.00
12-56-45 09-08-1995 09-08-1999 7,500.00
12-56-36 01-02-1998 01-02-0002 1,000.00
22-68-25 03-06-1994 03-06-1999 10,000.00
22-68-75 09-07-1997 09-07-1999 8,000.00
22-56-57 02-05-1994 02-05-1997 5,000.00
22-56-36 09-09-1996 09-09-1999 9,500.00
12-56-25 02-04-1993 02-04-1996 3,000.00
12-66-83 09-08-1995 09-08-1999 7,500.00
12-66-98 01-02-1998 01-22-@@03 2,000.00
22-68-75 03-06-1994 03-06-1999 10,000.00
22-68-56 09-07-1997 09-07- 01 8,000.00
22-76-54 02-05-1994 12-05-1997 5,000.00
22-76-23 09-09-1996 09-09-1999 9,500.00

456
Control-M/Analyzer User Guide

Figure 250 ON COMPARE Testing Rule – Example 2


EXECUTE 'RECONCIL'
ON_COMPARE
SOURCE1
DD 'DDBEFORE' PROCESS USERBLOCK 'USERBL'
SOURCE2
DD 'DD#AFTER'
ON_PARM MODE DS LINECT 80
WHEN FLINE 1 TLINE 999 FCOL 1 TCOL 1 SEARCH 'I'
DO EXTRACT 'LINE' LEVEL 0 LINE +0 FCOL 1 TCOL 80
DO SET 'OUT_LINE' EVAL 'SYSCURLINE'
DO PRINT DATA 'NOT OK ==> %%OUT_LINE'
EXECUTE ’END’
ON_DATA
ALWAYS
DO TERMINATE RESULT OK USER-CODE 0
EXECUTE 'USERBL'
ON_DATA
ALWAYS
DO SET 'CH' EVAL 'SUBSTR(2,1,SYSCURLINE)'
IF ISNUMBER(CH)
DO SET 'SYSCURLINE' EVAL 'SUBSTR(1,20,SYSCURLINE)//''19''
//SUBSTR(21,12,SYSCURLINE)//''19''//SUBSTR(33,100,SYSCURLINE)'

Figure 251 ON COMPARE Output – Example 2


These output lines refer to those lines in the DD#AFTER report of Table 257 that contain bolded items.
NOT OK ==> C U S T O M E R L I S T I N G
NOT OK ==> 12-56-36 01-02-1998 01-02-0002 1,000.00
NOT OK ==> 12-66-98 01-02-1998 01-22-@@03 2,000.00
NOT OK ==> 22-68-56 09-07-1997 09-07- 01 8,000.00

Note: After reconstructing the line, the lengths of the SOURCE1 and SOURCE2 lines must remain the
same in order for the comparison to determine that they are identical.
For examples of how the ON COMPARE statement can be used for converting currencies, see D Euro
Support (on page 678).

457
Control-M/Analyzer User Guide

ON DATA: Data Selection Statement


Processes Control-M/Analyzer variables.
Figure 252 ON DATA Statement

Type the word DATA (or its abbreviation DA) next to the ON label in the Rule Definition screen. When
Enter is pressed, an area is opened on the screen for specification of Data Identification statement IF or
ALWAYS.
Note: If DATA is accidentally specified, another data source type can be specified next to the ON in the
Rule Definition screen only after the contents of the ON field are erased. Erase the contents of the ON
field, and press Enter. Then specify the new data source type (by typing CLASS, COMPARE, DB2,
DDNAME, DSN, FILE, PAGE, SYSDATA, SYSOUT or VSAM) in the ON field.

General Information
The ON DATA statement processes information stored in Control-M/Analyzer Database, AutoEdit, Local,
and System variables.
ON DATA does not display the WHEN Data Identification statement. Instead, conditional or unconditional
execution of a group of processing statements is provided using the IF or ALWAYS Data Identification
statements. For more information, see IF: Data Selection Statement (on page 435) and ALWAYS: Data
Identification Statement (on page 358).
The DO EXTRACT statement is not available in an EXECUTE block that contains an ON DATA statement.

458
Control-M/Analyzer User Guide

Examples
Example 1
EXECUTE block INIT performs certain initialization steps before processing the report. These steps should
be performed every time the rule is invoked. Therefore, ON DATA statement ALWAYS is specified.
Figure 253 ON DATA Statement – Example 1
LIBRARY : CTB.PROD.RULES RULE : RULEMP
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE INIT UPON C
ON DATA
ALWAYS
DO SET = CNTR=0 C
DO SET = ERR=0 C
DO PRINT = UNREASONABLE SICK/VACATION DAYS F C
DO PRINT = ================================= F C
DO PRINT = +--+---------------+------+-----+ F C
DO PRINT = | NAME | SICK | VAC | F C
DO PRINT = +--+---------------+------+-----+ F C
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE INPUT UPON C
ON FILE FILENAME CTB.PROD.EMPREP
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 001 - 060 COL 013 - 014 STOP AND/OR
STRING = .AL.
DO EXTRACT = NAME
PLEASE FILL IN RULE DEFINITION. 16.48.58

Example 2
The EXECUTE block CHECK processes Control-M/Analyzer variables. This rule uses statement IF to
determine which DO statements to execute depending on the value of Control-M/Analyzer variable SUM.
Figure 254 ON DATA Statement – Example 2
LIBRARY : CTB.PROD.RULES RULE : RULCURR
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
EXECUTE CHECK UPON C
ON DATA
ALWAYS
DO PRINT = TOTAL SUM IS : %%SUM F C
DO
IF SUM > 1000000.00 C
DO SHOUT TO U-M18 URGENCY R
= PLEASE CHECK CURRENCY FILE; SUM COMPUTED IS %%SUM
DO REMARK = SUM IS OVER 1000000: SUM=%%SUM
DO COND = NOTOK-%%SYSJOBNAME 0704 +
DO TERMINAT = NOTOK COD 0055
DO
ELSE
DO REMARK = SUM IS NOT OVER 1000000: SUM=%%SUM
DO TERMINAT = OK COD 0000
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
PLEASE FILL IN RULE DEFINITION. 16.44.10

459
Control-M/Analyzer User Guide

Example 3
This is an example of a cross-run comparison. EXECUTE block PROCESS uses statement IF to compare
the current and previous values of Control-M/Analyzer Database variable CURRENT_TOTAL.
Figure 255 ON DATA Statement – Example 3
LIBRARY : CTB.PROD.RULES RULE : RUNCHK
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE PROCESS UPON C
ON DATA
IF (DB_CURRENT_TOTAL - DB_CURRENT_TOTAL@G01)> 10000 C
DO SHOUT TO OPER URGENCY R
= -- REPORT IS OUT OF BALANCE --- CALL 714-5678 - JOHN SMITH
DO TERMINAT = NOTOK COD 1501
DO
ELSE
DO TERMINAT = OK COD 0000
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 17.08.10

460
Control-M/Analyzer User Guide

ON DB2: Data Selection Statement


Processes data from DB2 tables using the dynamic SQL facility.
Figure 256 ON DB2 Statement Format

Type DB2 (or its abbreviation DB) to the right of ON in the Rule Definition screen. When Enter is
pressed, the following fields are displayed:
Table 258 ON DB2 Statement Fields

Field Description

SUBSYSTEM ID DB2 subsystem name, for which a connection will be made. A


maximum of four characters can be specified. Should begin with a
letter or one of the following characters: #, @, or $. Mandatory. For
details, refer to the IBM DATABASE 2 Administration Guide or the
database administrator (DBA) at the site.

SQL SELECTa Valid SQL SELECT statement. Mandatory.

C (Continue?) The C (Continue?) field, when set to Y (Yes), provides additional


space for specifying the SQL select statement. A maximum of 10
lines can be opened. Specifying N (No) in the C (Continue?) field
closes the following preexisting line.

MODE Determines the starting point upon which absolute WHEN line and
column specifications are based. (See WHEN: Rule Definition
Structure (on page 488).) Optional. Available modes are:
 DS (Dataset)–Line and column values are based on the start of
the dataset.
 PG (Page)–Line and column values are based on the start of the
page. Default.

461
Control-M/Analyzer User Guide

Field Description

LINECT Specifies the number of lines per printed page. Optional. If not
specified, the default is 60.

DATASTAMP Determines whether a unique Datastamp is calculated and assigned


to the data sources. For more information see Datastamp
Calculation (on page 442).
 blank – A Datastamp is not generated. Default.
 1 – A Datastamp is calculated using the original algorithm to
ensure compatibility with prior versions of Control-M/Analyzer.
 2 – A Datastamp is calculated using the newer, more efficient
algorithm.

General Information
The SQL statement must be a valid DB2 SQL SELECT statement. For additional information see the IBM
Database 2 (DB2), Application Programming and SQL Guide.
Note: The word SELECT is assumed. Do not include the word SELECT as part of the SQL SELECT
statement.
Control-M/Analyzer AutoEdit and Local variables may be embedded in the subparameters. The variables
are resolved (replaced) at time of rule execution. For additional information about AutoEdit processing see
Control-M/Analyzer Variables (on page 222).

SQL Output Format


The output of the SQL statement is formatted as a report with the various fields listed in order of their
appearance in the SQL SELECT statement and according to their field types (see Table 259). Therefore,
the total width of the output is the sum of the widths of the individual fields.
The width of each field is the maximum width of the field as defined in the DB2 table. The fields are
contiguous.
The following chart lists commonly used DB2 field types (including how field lengths are calculated) and
the Control-M/Analyzer built-in process used by the DO EXTRACT statement to process the value of the
extracted DB2 field. For information about other DB2 field types, refer to your DB2 documentation.

462
Control-M/Analyzer User Guide

Table 259 Commonly-Used DB2 Field Types and Control-M/Analyzer Built-In Process
Used by DO EXTRACT to Extract their Values

Field Type Description/Structure Length Built-in Process

CHARACTER(n) String n None required

VARCHAR(n) Variable length character string. The n+2 Start extraction


first 2 bytes contain the actual string from third byte
length

SMALLINT Halfword binary integer 2 BBINH

INTEGER Fullword binary integer 4 BBINF

DECIMAL(p,s) Decimal value. Precision (p) is the total INT (p/2+0.5) BUNPKs
NUMERIC(p,s) number of digits. Scale (s) is the
number of digits after the implied
decimal point.

DATE System datea 10 None required

TIME Time, according to a 24-hour clocka 8 None required

TIMESTAMP Date and time (as previously defined by 26 (including None required
DATE and TIME type fields)a microseconds)

All field types that may contain a NULL value (NULL=YES as defined in DB2) include an additional X ‘00’ at
the end of the field. Therefore, the field length for these field types should be increased by one. The
maximum length of a value that Control-M/Analyzer can extract is 100 bytes. When extracting fields from
DB2 files, BMC recommends that each field be extracted individually. Do not extract an entire line from a
DB2 file into one field. If a field in the DB2 table is empty (NULL), the field is padded with X ‘00’ when
extracted by Control-M/Analyzer.
To receive information on DB2 table column lengths and types, the database administrator can issue the
following DB2 command:
SELECT * FROM SYSIBM.SYSCOLUMNS WHERE TBCREATOR='creator' AND TBNAME='name';

where
 SYSIBM.SYSCOLUMNS is the name of the DB2 system table that describes every column of every
defined table.
 name is the name of a DB2 table.
 creator is the creator of a DB2 table.

463
Control-M/Analyzer User Guide

Example
Assume the following employee table EMPTABLE exists:
Table 260 Contents of EMPTABLE for ON DB2 Statement Example

DB2 Control-M/
Field Analyzer Field
Field Name Description Field Type Nulls Length Length

EMPNO Employee # CHAR no 8 8

EMPNAME Employee name VARCHAR no 20 22

EMPHIREDATE Date hired DATE yes 4 11

EMPRANK Employee rank SMALLINT no 2 2

EMPSALARY Gross salary DECIMAL(10,2) no 5 5

The following rule definition instructs Control-M/Analyzer to retrieve and print information about
employees whose salaries are over 3,000:
Figure 257 ON DB2 Statement Example
LIBRARY : CTBP.PROD.RULES RULE : EMPSAL
COMMAND ===> SCROLL===>CRSR
+-----------------------------------------------------------------------------+
OWNER M43 GROUP PERSONNEL
UPDATED 08/08/00 - 10:20:09 BY M43
DESC
OPTIONS
================================================================================
EXECUTE GETAVG UPON C
ON DB2 SUBSYSTEM ID S111
SQL SELECT EMPNAME,SALARY FROM EMPTABLE WHERE SALARY>3000 C
MODE DS LINECT 0000 DATASTAMP
WHEN LINE 001 - 999 COL 001 - 001 STOP AND/OR
STRING = .AL.
DO EXTRACT = EMPNAME
LEVEL LINE +000 COL 0003 - 0022 PROCESS TYP
DO EXTRACT = EMPSALARY
LEVEL LINE +000 COL 0023 - 0027 PROCESS BUNPK2 TYP
DO PRINT = %%EMPNAME %EMPSALARY F C
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
=================================================================================
EXECUTE UPON C
PLEASE FILL IN RULE DEFINITION. 11.42.28

In the example:
 Extraction of the EMPNAME field starts at column 3, even though according to its width, it should
begin at column 1. This is because the EMPNAME field is of type VARCHAR, and the first two bytes,
columns 1 and 2, contain the length of the field.
 Built-in process BUNPK2 is used to extract the employee salary and rank.

464
Control-M/Analyzer User Guide

ON DDNAME: Data Selection Statement


Processes the sequential datasets referenced by the specified DD statement in the current step.
Figure 258 ON DDNAME Statement Format

Type DDNAME (or its abbreviation DD) to the right of ON in the Rule Definition screen. When Enter is
pressed, the following fields are displayed:
Table 261 ON DDNAME Statement Fields

Field Description

DDNAME Name of the DD statement. DDNAME can have a maximum of 8


characters. Mandatory.

MODE Determines the starting point for calculating WHEN statement line
and column specifications. See WHEN: Rule Definition Structure (on
page 488). Optional. Available values are:
 DS (Dataset) – Line and column values are based on the start of
the dataset.
 PG (Page) – Line and column values are based on the start of
the page. Default.

LINECT Specifies number of lines per printed page. Optional. If not


specified, the default is 60.

DATASTAMP Determines whether a unique Datastamp is calculated and assigned


to the data sources. For more information see Datastamp
Calculation (on page 442).
 blank — A Datastamp is not generated. Default.
 1 — A Datastamp is calculated using the original algorithm to
ensure compatibility with prior versions of Control-M/Analyzer.
 2 — A Datastamp is calculated using the newer, more efficient
algorithm.

465
Control-M/Analyzer User Guide

General Information
Control-M/Analyzer processes the sequential dataset referenced by the specified DD name in the current
step (that is, the Control-M/Analyzer invocation step, or a step executing an application program that
invokes Control-M/Analyzer by a program call).
To check temporary files created by previous steps, pass these files to the Control-M/Analyzer invocation
step with JCL parameter DISP=PASS.
Control-M/Analyzer AutoEdit and Local variables can be embedded in the DDNAME parameter. The
variables are resolved (replaced) at time of rule execution. For additional information on AutoEdit
processing see Control-M/Analyzer Variables (on page 222).

Example
The ON DDNAME statement identifies the report created in the current step that is referenced by DD
statement REPORT.
Figure 259 ON DDNAME Statement Example
LIBRARY : CTB.PROD.RULES RULE : ONDDNAME
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE INPUT UPON C
ON DDNAME DDNAME REPORT
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 001 - 060 COL 010 - 020 STOP AND/OR
STRING = /
DO EXTRACT = SALARY
LEVEL 0 LINE +000 COL +002 - +008 PROCESS TYP
DO BLOCK = CHECK ARG SALARY C
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE CHECK UPON BARG01 < 1000 | BARG01 > 20000 C
ON DATA
ALWAYS
DO PRINT = %%BARG01 F C
DO
(ENTER "ALWAYS", "IF")
PLEASE FILL IN RULE DEFINITION. 16.30.11

466
Control-M/Analyzer User Guide

ON DSN: Data Selection Statement


Processes one or more Compressed Dataset Access Method (CDAM) files. For sites where Control-D or
Control-V are installed.
Figure 260 ON DSN Statement Format

Type the word DSN (or its abbreviation DS) to the right of ON in the Rule Definition screen. When Enter
is pressed, the = prompt and the following fields are displayed:
Table 262 ON DSN Statement Fields

Field Description

criteria Selection criteria for one or more Compressed Dataset Access


Method (CDAM) files. CDAM selection criteria must be specified.
A maximum of 6 lines can be used to specify the criteria. Specify Y
(Yes) in the C (Continue?) field to open another line for the
continuation of the criteria. Specify N (No) in the C (Continue?) field
to close the criteria field.

MODE Determines the starting point for calculating WHEN statement line
and column specifications. See WHEN: Rule Definition Structure (on
page 488). Optional. Available modes are:
 DS (Dataset) — Line and column values are based on the start
of the dataset.
 PG (Page) — Line and column values are based on the start of
the page. Default.

LINECT Specifies number of lines per printed page. Optional. If not


specified, the default is 60.

467
Control-M/Analyzer User Guide

Field Description

DATASTAMP Determines whether a unique Datastamp is calculated and assigned


to the data sources. For more information see Datastamp
Calculation (on page 442).
 blank – A Datastamp is not generated. Default.
 1 – A Datastamp is calculated using the original algorithm to
ensure compatibility with prior versions of Control-M/Analyzer.
 2 – A Datastamp is calculated using the newer, more efficient
algorithm.

General Information
ON DSN processes all compressed sysouts that meet the selection criteria specified in the ON DSN field.
The selection criteria specified must be a valid Compressed Dataset Access Method (CDAM) retrieval
parameter such as PREFIX or PGMSTEP. For a list of all valid CDAM parameters, see the Control-D User
Guide or the Control-V User Guide. It is possible to process CDAM files created by the Control-D monitor
during decollation or files created by applications that write to CDAM directly.
Note: Rules that contain an ON DSN statement that refers to a CDAM file can properly function only when
the CDAM file line length is 300 characters or less.

Example
The ON DSN statement identifies a compressed dataset referenced by DD statement REPORT in program
step STEP5 with higher level dataset name qualifier SALARY.
Figure 261 ON DSN Statement Example
LIBRARY : CTB.PROD.RULES RULE :CHKSAL
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE INPUT UPON C
ON DSN = PREFIX=SALARY,DDNAME=REPORT,PGMSTEP=STEP5
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 001 - 0060 COL 010 - 020 STOP AND/OR
STRING = /
DO EXTRACT = SALARY
LEVEL 0 LINE +000 COL +002 - +008 PROCESS TYP
DO BLOCK = CHECK ARG SALARY C
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE CHECK UPON BARG01 < 1000 | BARG01 > 20000 C
ON DATA
LABEL:
ALWAYS
DO PRINT = %%BARG01 F C
DO
PLEASE FILL IN RULE DEFINITION. 16.30.50

468
Control-M/Analyzer User Guide

ON FILE: Data Selection Statement


Processes a sequential dataset.
Figure 262 ON FILE Statement Format

Type the word FILE (or its abbreviation F) to the right of ON in the Rule Definition screen. When Enter is
pressed, the following fields are displayed:
Table 263 ON FILE Statement Fields

Field Description

FILENAME Specifies the name of the sequential dataset. FILENAME can have a
maximum of 44 characters. Mandatory.

MODE Determines the starting point for calculating WHEN statement line
and column specifications. See WHEN: Rule Definition Structure (on
page 488). Optional. Available modes are:
 DS (Dataset) — Line and column values are based on the start
of the dataset.
 PG (Page) — Line and column values are based on the start of
the page. Default.

LINECT Specifies number of lines per printed page. Optional. If not


specified, the default is 60.

DATASTAMP Determines whether a unique Datastamp is calculated and assigned


to the data sources. See Datastamp Calculation (on page 442)
earlier in this chapter for more information.
 blank – A Datastamp is not generated. Default.
 1 – A Datastamp is calculated using the original algorithm to
ensure compatibility with prior versions.
 2 – A Datastamp is calculated using the newer, more efficient
algorithm.

469
Control-M/Analyzer User Guide

General Information
Control-M/Analyzer dynamically allocates the sequential dataset or PDS member. Allocation is in shared
mode. The dataset must exist and be cataloged.
Control-M/Analyzer AutoEdit and Local variables can be embedded in the FILENAME parameter. The
variables are resolved (replaced) at time of rule execution. For additional information on AutoEdit
processing see Control-M/Analyzer Variables (on page 222).

Example
EXECUTE block INPUT processes the sequential file named CTB.PROD.EMPREP. The file is read line by
line. Employee details are extracted from each line that contains the symbol "#" in column 15.
Figure 263 ON FILE Statement Example
LIBRARY : CTB.PROD.RULES RULE : RULEMP
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
===========================================================================
EXECUTE INPUT UPON C
ON FILE FILENAME CTBT.PROD.EMPRE
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 001 - 060 COL 015 - 015 STOP AND/OR
STRING = #
DO EXTRACT = NAME
LEVEL 0 LINE +000 COL -002 - +013 PROCESS TYP
DO EXTRACT = SICK
LEVEL 0 LINE +000 COL +087 - +088 PROCESS TYP
DO EXTRACT = VAC
LEVEL 0 LINE +000 COL +093 - +094 PROCESS TYP
DO BLOCK = CHECK ARG NAME,SICK,VAC C
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE FIN UPON C
ON DATA
PLEASE FILL IN RULE DEFINITION. 16.00.22

470
Control-M/Analyzer User Guide

ON PAGE: Data Selection Statement


Processes pages passed to Control-M/Analyzer. For Control-D and Control-V users.
Figure 264 ON PAGE Statement Format

Type the word PAGE (or its abbreviation P) to the right of ON in the Rule Definition screen. When Enter
is pressed, the following fields are displayed:

471
Control-M/Analyzer User Guide

Table 264 ON PAGE Statement Fields

Field Description

MODE Determines the starting point for calculating WHEN statement line
and column specifications. See WHEN: Rule Definition Structure (on
page 488). Optional. Available modes are:
 DS (Dataset) — Line and column values are based on the start
of the dataset.
 PG (Page) — Line and column values are based on the start of
the page. Default.

LINECT Specifies number of lines per printed page. Optional. If not


specified, the default is 60.

DATASTAMP Determines whether a unique Datastamp is calculated and assigned


to the data sources. See Datastamp Calculation (on page 442) for
more information.
 blank – A Datastamp is not generated. Default.
 1 – A Datastamp is calculated using the original algorithm to
ensure compatibility with prior versions.
 2 – A Datastamp is calculated using the newer, more efficient
algorithm.

General Information
Control-M/Analyzer processes each page that the Control-D or Control-V monitor passes (for example,
each page that matches Control-D or Control-V WHEN criteria). The rule is executed once for each page.
ON PAGE can be specified in rule definitions that are invoked by statement DO CTBRULE in a Control-D or
Control-V decollating mission definition. Within the rule definition, Control-M/Analyzer System variable
SYSOPT contains one of the following values when Control-M/Analyzer is invoked by Control-D or
Control-V:

472
Control-M/Analyzer User Guide

Table 265 Control-M/Analyzer System Variable SYSOPT Value when Control-M/Analyzer


is invoked by Control-D or Control-V

Value Description

CTDFIRST Control-D or Control-V has started scanning report pages but report
pages have not yet been sent to Control-M/Analyzer.

CTDWORK CDAM pages that match Control-D or Control-V WHEN criteria are
being sent to and processed by Control-M/Analyzer.

CTDLAST All report pages have been processed (unless statement DO


TERMINAT was not processed during the CTDFIRST and CTDWORK
stages).

The ON PAGE statement is executed only when SYSOPT=CTDWORK is specified in the UPON statement of
the EXECUTE block.
For additional information see Interface to Control-D and Control-V (on page 637).

Example
EXECUTE block GETTOTAL processes each CDAM page received from the Control-D or Control-V monitor
during report decollation. The invoice total on each page is extracted and totalled.
Figure 265 ON PAGE Statement Example
LIBRARY : CTB.PROD.RULES RULE : ADDTOTAL
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M43 GROUP INVOICING
UPDATED 08/08/00 - 11:53:45 BY M43A
DESC CALCULATE AMOUNT DUE THE COMPANY BASED ON INVOICES
OPTIONS
===========================================================================
EXECUTE GETTOTAL UPON SYSOPT='CTDWORK' C
ON PAGE
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 012 - 060 COL 050 - 060 STOP AND/OR
STRING = TOTAL DUE
DO EXTRACT = INVTOTAL
LEVEL 0 LINE +000 COL 0061 - 0075 PROCESS TYP SU
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE CHECKTOT UPON SYSOPT='CTDLAST' C
ON DATA
IF INVTOTAL=DB_INVTOTAL C
PLEASE FILL IN RULE DEFINITION. 12.09.28

473
Control-M/Analyzer User Guide

ON SYSDATA: Data Selection Statement


Processes the three SYSDATA job sysout datasets. For Control-M and Control-M/Restart users only.
Figure 266 ON SYSDATA Statement Format

Type the word SYSDATA (or its abbreviation SYSD) next to the ON in the Rule Definition screen. When
you press Enter, the following fields are displayed:

474
Control-M/Analyzer User Guide

Table 266 ON SYSDATA Statement Fields

Field Description

MODE Determines the starting point for calculating WHEN statement line
and column specifications. See WHEN: Rule Definition Structure (on
page 488). Optional. Available modes:
 DS (Dataset) — Line and column values are based on the start
of the dataset.
 PG (Page) — Line and column values are based on the start of
the page. Default.

LINECT Specifies number of lines per printed page. Optional. If not


specified, the default is 60.

DATASTAMP Determines whether a unique Datastamp is calculated and assigned


to the data sources. For more information see Datastamp
Calculation (on page 442).
 blank – A Datastamp is not generated. Default.
 1 – A Datastamp is calculated using the original algorithm to
ensure compatibility with prior versions.
 2 – A Datastamp is calculated using the newer, more efficient
algorithm.

General Information
Control-M/Analyzer processes the three SYSDATA datasets that the Control-M monitor archives (if
Control-M/Restart is also installed) when analyzing job runs. These datasets include: job log (console
messages), expanded JCL, and system output messages.
ON SYSDATA can be specified in rule definitions that are invoked by the DO CTBRULE statement in a
Control-M job scheduling definition. Control-M/Analyzer is invoked each time the DO CTBRULE statement
is encountered in the job scheduling definition.
If a DO CTBRULE statement follows ON PGMST ANYSTEP in the job scheduling definition,
Control-M/Analyzer is invoked once. See the discussion about the Scheduling Definition Facility in the
Control-M for z/OS User Guide for more information.
Within the rule definition, Control-M/Analyzer System variable SYSOPT contains the value CTMWORK if
the rule was invoked by Control-M. For additional information see Interface to Control-M (on page 633).

Example
EXECUTE block GETTIME extracts the execution time of the job that invoked Control-M/Analyzer by
analyzing the job sysouts. If the job execution time exceeds half an hour, a message is "shouted"
recommending that the job be run at night.

475
Control-M/Analyzer User Guide

Figure 267 ON SYSDATA Statement Example


LIBRARY : CTB.PROD.RULES RULE : CHECKTIM
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M43A GROUP OPERATIONS
UPDATED 08/08/00 - 10:59:04 BY M43A
DESC CHECK JOB EXECUTION TIME
OPTIONS
===========================================================================
EXECUTE GETTIME UPON SYSOPT='CTMWORK' C
ON SYSDATA
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 001 - 060 COL 014 - 040 STOP AND/OR
STRING = MINUTES EXECUTION TIME
DO EXTRACT = EXECTIME
LEVEL 0 LINE +000 COL 0001 - 0013 PROCESS TYP
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE CHECKTIM UPON SYSOPT='CTMWORK' C
ON DATA
IF EXECTIME GT 50 C
DO SHOUT TO TSO-M14 URGENCY R
= RUN JOB AT NIGHT INSTEAD
(ENTER "ALWAYS" OR "IF")
===========================================================================
PLEASE FILL IN RULE DEFINITION. 11.05.18

476
Control-M/Analyzer User Guide

ON SYSOUT: Data Selection Statement


Processes sysouts of a previous step referenced by the specified DD statements.
Figure 268 ON SYSOUT Statement Format

Type the word SYSOUT (or its abbreviation SYSO) next to the ON in the Rule Definition screen. When
Enter is pressed, the following fields are displayed:
Table 267 ON SYSOUT Statement Fields

Field Description

PROCST Name of the procedure step. PROCST can have a maximum of 8


characters and cannot start with a number. Optional.

PGMST Name of the program step. PGMST can have a maximum of 8


characters and cannot start with a number. Optional.

DDNAME Name of the DD statement. DDNAME can have a maximum of 8


characters and cannot start with a number. Mandatory.

JOBNM Name of the job whose sysout is to be processed. JOBNM must be a


valid job name. Optional.

MODE Determines the starting point for calculating WHEN statement line
and column specifications. See WHEN: Rule Definition Structure (on
page 488). Optional. Available modes are:
 DS (Dataset) — Line and column values are based on the start
of the dataset.
 PG (Page) — Line and column values are based on the start of
the page. Default.

477
Control-M/Analyzer User Guide

Field Description

LINECT Specifies number of lines per printed page. Optional. If not


specified, the default is 60.

DATASTAMP Determines whether a unique Datastamp is calculated and assigned


to the data sources. See Datastamp Calculation (on page 442) for
more information.
 blank – Datastamp is not generated. Default.
 1 – Datastamp is calculated using the original algorithm to
ensure compatibility with prior versions.
 2 – A Datastamp is calculated using the newer, more efficient
algorithm.

General Information
Control-M/Analyzer reads the specified sysout according to the specified DD name, procedure step, and
program step. The sysout must have been written by a previous step.
When ON SYSOUT is specified, the output must be in HELD state and FREE=CLOSE must be specified in
the DD statement that references the output.
ON SYSOUT can be specified under both JES2 and JES3.
Control-M/Analyzer AutoEdit and Local variables can be embedded in the PROCSTEP, PGMSTEP, DDNAME,
and JOBNM parameters. The variables are resolved (replaced) at time of rule execution. For additional
information on AutoEdit processing see Control-M/Analyzer Variables (on page 222).
If the JOBNM parameter is not specified, the sysout of the current job is processed. Otherwise, the job
name of every sysout in the system is examined to find the most recently produced sysout with the
specified job name. If the specified job name is not found, no sysout is processed.

478
Control-M/Analyzer User Guide

Example
EXECUTE block INIT processes the sysout file referred to by DD statement SYSUT2 in program step
STEP2 of job WRHSE1.
Figure 269 ON SYSOUT Statement Example
LIBRARY : CTB.PROD.RULES RULE : CHKINV
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M42 GROUP WHSE
UPDATED 08/08/00 - 17:34:49 BY M42
DESC
OPTIONS
============================================================================
EXECUTE INIT UPON C
ON SYSOUT PROCST PGMST STEP2 DDNAME SYSUT2 JOBNM WRHSE1
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 001 - 050 COL 001 - 080 STOP AND/OR
STRING = WAREHOUSE NO:
DO EXTRACT = WAREHOUSE_NUMBER
LEVEL 0 LINE +000 COL +001 - +002 PROCESS TYP
DO = F C
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 09.41.01

479
Control-M/Analyzer User Guide

ON VSAM: Data Selection Statement


Processes VSAM file records using user-specified keys.
Figure 270 ON VSAM Statement Format

Type the word VSAM (or its abbreviation V) next to the ON in the Rule Definition screen. When Enter is
pressed, the following fields appear:
Table 268 ON VSAM Statement Fields

Field Description

FILENAME Valid VSAM, KSDS, ESDS or RRDSa dataset name. Mandatory. A


maximum of 44 characters can be specified.

FIRSTKEY Key of the first KSDS file record or RBA of the first RRDS/ESDS file
record to be processed. Optional. If FIRSTKEY is blank, processing
starts from the first record in the file.
The C (Continue?) field, when set to Y (Yes), provides additional
space for specifying the FIRSTKEY field. A maximum of six lines may
be opened for this field. Specifying N (No) in the C (Continue?) field
closes the following preexisting line.

LASTKEY Key of the last KSDS file record or RBA of the last RRDS/ESDS file
record to be processed. Optional. If LASTKEY is blank, processing
ends with the last record in the file. The last record is read by
Control-M/Analyzer.
The C (Continue?) field, when set to Y (Yes), provides additional
space for specifying the LASTKEY field. A maximum of six lines may
be opened for this field. Specifying N (No) in the C (Continue?) field
closes the following preexisting line.

T VSAM file type. Valid values are: ESDS, RRDS and KSDS.

480
Control-M/Analyzer User Guide

Field Description

MODE Determines the starting point upon which absolute WHEN line and
column specifications are based. For more information, see WHEN:
Rule Definition Structure (on page 488). Optional. Available modes
are:
 DS (Dataset) – Line and column values are based on the start of
the dataset.
 PG (Page) – Line and column values are based on the start of
the page. Default.

LINECT Specifies the number of lines per printed page. Optional. If not
specified, Control-M/Analyzer assumes a value of 60.

DATASTAMP Determines whether a unique Datastamp is calculated and assigned


to the data sources. See Datastamp Calculation (on page 442) for
more information.
 blank – A Datastamp is not generated. Default.
 1 – A Datastamp is calculated using the original algorithm to
ensure compatibility with prior versions.
 2 – A Datastamp is calculated using the newer, more efficient
algorithm.

General Information
FIRSTKEY and LASTKEY should be composed of a concatenation of fields only of the following types:
Table 269 Legal Field Types for Composition of FIRSTKEY and LASTKEY Fields

Type Description

Alphanumeric string C‘aaa’ (for example, C‘TOTAL1’)

Hexadecimal X‘nnnn’ (for example, X‘12AB’), where ‘nnnn’ must be an even


number of digits.

Note: For packed decimal and/or zoned decimal support, use the hexadecimal representation of these
numbers.
The key value is created by concatenation of the strings. This way, a key that contains both alphanumeric
and hexadecimal strings can be specified.
If the specified key is shorter than the actual KEYLEN of the VSAM file, the specified key is padded by
hexadecimal ‘00’ characters for FIRSTKEY and hexadecimal ‘FF’ characters for LASTKEY. This enables
GENKEY access.

481
Control-M/Analyzer User Guide

The output of ON VSAM is identical to the output of the IDCAMS REPRO command, specified with similar
parameters (for example, you can extract the information with reference to the original columns in the
VSAM file in accordance with the record layout). Please refer to the IBM VSAM Administration Guide for
additional information on the REPRO command.

Examples
Example 1
This example extracts and prints the salary of all employees whose last name begins with any letter
between A and P, inclusive:
Figure 271 ON VSAM Statement – Example 1
LIBRARY : CTBP.PROD.RULES RULE : VSAM
COMMAND === SCROLL=== CRSR
+-----------------------------------------------------------------------------+
OWNER M42 GROUP PRO
UPDATED 08/08/00 - 14:22:41 BY M42B
DESC
OPTIONS
===========================================================================
EXECUTE SALARY UPON C
ON VSAM FILENAME ACC.PROJ1.SALARY T KSDS
FIRSTKEY = C'A' C
LASTKEY = C'P' C
MODE DS LINECT 0000 DATASTAMP
WHEN LINE 001 - 999 COL 001 - 020 STOP AND/OR
STRING = .AL.
DO EXTRACT = EMPNAME
LEVEL LINE +000 COL 0001 - 0020 PROCESS TYP
DO EXTRACT = EMPSALARY
LEVEL LINE +000 COL 0021 - 0032 PROCESS TYP
DO PRINT = SALARY = '%%EMPNAME %%EMPSALARY' F C
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====
PLEASE FILL IN RULE DEFINITION. 14.33.21

482
Control-M/Analyzer User Guide

Example 2
This example extracts and prints the salary of employees listed in the 2nd through 9th records of an
RRDS type VSAM file.
Figure 272 ON VSAM Statement – Example 2
LIBRARY : CTBP.PROD.RULES RULE : RULRRDS
COMMAND ===> SCROLL===> CRSR
+------------------------------------------+
OWNER M42 GROUP PROD
UPDATED 08/08/00 - 12:34:12 BY M42
DESC
OPTIONS
===========================================================================
EXECUTE SALARY UPON C
ON VSAM FILENAME ACCT.VSAM.RRDS T RRDS
FIRSTKEY = C'2' C
LASTKEY = C'9' C
MODE DS LINECT 0000 DATASTAMP
WHEN LINE 001 - 999 COL 001 - 001 STOP AND/OR
STRING = .AL.
DO EXTRACT = EMPNAME
LEVEL 0 LINE +000 COL 0001 - 0020 PROCESS TYP
DO EXTRACT = SALARY
LEVEL 0 LINE +000 COL 0071 - 0080 PROCESS TYP
DO PRINT = %%EMPNAME F C
DO PRINT = %%SALARY F C
DO
WHEN LINE - COL - STOP AND/OR
PLEASE FILL IN RULE DEFINITION. 11.50.15

Example 3
This example extracts and prints the salary of employees listed in the 2nd through 12th records of an
ESDS type VSAM file with 80-character records.
Figure 273 ON VSAM Statement – Example 3
LIBRARY : CTBP.PROD.RULES RULE : RULESDS
COMMAND ===> SCROLL===> CRSR
+-------------------------------------+
OWNER M42 GROUP PROD
UPDATED 08/08/00 - 12:33:12 BY M42
DESC
OPTIONS
===========================================================================
EXECUTE SALARY UPON C
ON VSAM FILENAME PROD.VSAM.ESDS T ESDS
FIRSTKEY = C'080' C
LASTKEY = C'880' C
MODE DS LINECT 0000 DATASTAMP
WHEN LINE 001 - 999 COL 001 - 001 STOP AND/OR
STRING = .AL.
DO EXTRACT = EMPNAME
LEVEL 0 LINE +000 COL 0001 - 0020 PROCESS TYP
DO EXTRACT = SALARY
LEVEL 0 LINE +000 COL 0071 - 0080 PROCESS TYP
DO PRINT = %%EMPNAME F C
DO PRINT = %%SALARY F C
DO
WHEN LINE - COL - STOP AND/OR
PLEASE FILL IN RULE DEFINITION. 12.20.18

483
Control-M/Analyzer User Guide

OPTIONS: Basic Rule Parameter


For future use.
Figure 274 OPTIONS Parameter Format

484
Control-M/Analyzer User Guide

OWNER: Basic Rule Parameter


Identifies the user who requests Control-M/Analyzer balancing services. This parameter is mainly used by
the Control-M/Analyzer security mechanism.
Figure 275 OWNER Parameter Format

Mandatory. OWNER must be 1 to 8 characters.

General Information
OWNER is used by the internal security mechanism of Control-M/Analyzer to determine those operations
that each user is authorized to perform.
The OWNER parameter is also used to enable more convenient handling of missions and rules. When
using the Online Tracking and Control facility, you can limit the display of Control-M/Analyzer information
to specified owners.
OWNER is used in interactions with external security products, such as TOP SECRET, RACF, and ACF2.
The value of the OWNER parameter is based on the method of Control-M/Analyzer invocation:
 Direct invocation by a job step or program
The OWNER is specified on the Rule Definition screen by the creator of the rule.
 Invocation by mission
The OWNER receives its value from the mission definition.
 Invocation by other INCONTROL products
When the rule is called by the DO CTBRULE statement in Control-M, Control-D, or Control-V, OWNER
receives its value from the Control-M job scheduling definition, or the Control-D or Control-V
decollating mission.

485
Control-M/Analyzer User Guide

Example
Figure 276 OWNER Statement Example
LIBRARY : CTB.PROD.RULES RULE : CHECKCUR
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M55 GROUP CURRENCY
UPDATED 08/08/00 - 09:18:35 BY M55A
DESC CHECK BALANCING OF BANK'S FOREIGN CURRENCY INVESTM
OPTIONS
===========================================================================
EXECUTE CHECK UPON C
ON SYSOUT PROCST PGMST DDNAME REPORT JOBNM
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 020 - 030 COL 001 - 132 STOP AND/OR
STRING = NOT BALANCED
DO SHOUT TO OPER URGENCY R
= FOREIGN CURRENCY REPORT NOT BALANCED !!!
DO TERMINAT = NOTOK COD 1001
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 09.25.30

486
Control-M/Analyzer User Guide

UPDATED... BY: Basic Rule Parameter


Displays the date and time the rule was last updated, plus the user who last updated the rule.

Format
This parameter is set by Control-M/Analyzer and cannot be changed. For display only.

General Information
The date and time are reset each time the rule is modified.

Example
Figure 277 UPDATE ... BY Parameter Example
LIBRARY : CTB.PROD.RULES RULE : CHECKCUR
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M55 GROUP CURRENCY
UPDATED 08/08/00 - 09:18:35 BY M55A
DESC CHECK BALANCING OF BANK'S FOREIGN CURRENCY INVESTM
OPTIONS
===========================================================================
EXECUTE CHECK UPON C
ON SYSOUT PROCST PGMST DDNAME REPORT JOBNM
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 020 - 030 COL 001 - 132 STOP AND/OR
STRING = NOT BALANCED
DO SHOUT TO OPER URGENCY R
= FOREIGN CURRENCY REPORT NOT BALANCED !!!
DO TERMINAT = NOTOK COD 1001
===========================================================================
EXECUTE UPON C
ON
====== >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 09.25.35

487
Control-M/Analyzer User Guide

WHEN: Rule Definition Structure


Searches for a specified string on a line-by-line basis.
Figure 278 WHEN Structure Format

Mandatory for all ON statements except ON DATA.


Note: These parameters are available for all ON statements except ON DATA.
Table 270 WHEN Structure Parameters

Parameter Description

LINE Line range to be searched.

FROM LINE A 3-digit number from 001 through 999. Mandatory.

UNTIL LINE A 3-digit number from 001 through 999, greater than or equal to
FROM LINE. Mandatory.

COL Column range to be searched.

FROM COL A 3-digit number from 001 through 999. Mandatory.

UNTIL COL A 3-digit number from 001 to 999, greater than or equal to FROM
COL plus the length of the specified string minus 1. Mandatory.

Note: The line and column positions can also be specified using relative values (for
example, the first line of the current page, plus an offset value). For more information, see
Search Areas (LINE and COL Parameters) (on page 495).
When search strings are joined by a Boolean operator (for example, .AND. or .OR.), the
values specified in the COL parameter are ignored and data is extracted from the first
column in the specified line range.

488
Control-M/Analyzer User Guide

Parameter Description

STOP Determines if STOP criteria are to be specified:


 blank – STOP area is not opened.
 Y (Yes) – STOP area is opened for STOP criteria.
 N (No) – STOP area is closed.

AND/OR When A (And) or O (Or) is specified, an additional WHEN line is


opened on the screen.
 A – Another WHEN line is opened. The expression resolves to
true only if both WHEN conditions are satisfied. Use this option
when two (or more) distinct strings must be found to identify
the data.
 O – For future use.
 N – The following WHEN line is closed.

STRING The string to search for. The string can be up to 50 characters in


length. If you need to use a longer identification string, specify
another WHEN statement using the AND parameter.
The string may contain blanks. The length of the string to be
located is measured from the start of the field to the last non-blank
character. To search for a string with trailing blanks, embed the
string in quotes (for example, ‘TRAILING BLANKS’).
STRING can contain logical comparison operators. The format of the
string when it contains these operators is:
STRING =.op.string
STRING =.op.string .AND.op.string
STRING =.op.string .OR.op.string
where

489
Control-M/Analyzer User Guide

Parameter Description

STRING  op is the operator. Periods on both sides of the operator are


mandatory. The first op must start in the first column of the
(continued)
STRING field. Operators .GT., .LT., .GE., .LE., and .NE. must be
followed (without extra blanks) by a string specification. The
following operators are supported:
Comparison Operators
— .GT.–Greater than
— .LT.–Less than
— .GE.–Greater than or equal to
— .LE.–Less than or equal to
— .NE.–Not equal to
Wild-character Mask Operator
— .WI.–Wild-character search mask
Location Operators
— These operators do not require a string.
— .AL.–All
— .SR.–Start of report
— .ER.–End of report
— .SP.–Start of page
— .EP.–End of page
Boolean Operators
— .AND.
— .OR.
For additional information, see "STRING Operators" below.
One or more Boolean operators (.AND. and .OR.) can be used with
comparison operators .GT., .LT., .GE., .LE., and .NE. When both
.AND.s and .OR.s. are used in the same STRING parameter, the
.AND. operators are evaluated (resolved) before the .OR. operators.
Examples
 STRING=.GE.0 .AND. .LE.9
 STRING=.NE.' TOTAL ' .AND. .NE.' SUBTOTAL '
 STRING= MR. .OR.MS. .OR.MRS .OR.DR.
 STRING=.NE.' ' .AND. .NE.'0'
Examples 8 and 9 below illustrate how the .AND. and .OR. Boolean
operators are used to facilitate data extraction.

490
Control-M/Analyzer User Guide

Parameter Description

STRING  string is the string used for comparison. The string can contain
leading blanks and can be surrounded by quotes.
(continued)
The comparison is performed character by character, left to right.

Note: For comparison operators, the length of the string must not
exceed the length between the FROM COLUMN and UNTIL COLUMN
parameters, inclusive.

STOP criteria LINE and COL ranges to be searched and the STOP string to search
for. Formats are identical to the parameters above. Optional.

General Information
Parameters that immediately follow statement WHEN in the Rule Definition screen provide additional
criteria for identifying data. The search is performed on the data source type specified by statement ON.
When Control-M/Analyzer finds data that match the STRING specification, the current position is set to
the position of the first character of the located string in the data source.
Details of the search process are provided below. See "Single vs. Multiple Occurrences of a String" in
Search Areas (LINE and COL Parameters) (on page 495) for an explanation of how system variable
SYSSRCHALL affects the search process.

WHEN Blocks
Each WHEN and its parameters (including STOP criteria) form a WHEN statement. Single WHEN
statements can be linked together by the AND and/or OR parameters (note, for future use) to form a
compound WHEN statement. (See "Compound WHEN Statements" below.)
WHEN statements and subsequent DO statements form a WHEN block. Each EXECUTE block that does
not contain an ON DATA statement must contain at least one WHEN block.

491
Control-M/Analyzer User Guide

Figure 279 Compound WHEN Statements

If the WHEN statement criteria are satisfied, the DO statements in that WHEN block are performed. If the
string specified in a WHEN statement occurs more than once in the searchable column range of a line,
system variable SYSSRCHALL determines whether the DO statements are performed only once or as
many times as the search string occurs. See Summary of System Variables (on page 262) for a
description of this system variable.

Compound WHEN Statements


Compound WHEN statements are used when multiple search criteria must be met before
Control-M/Analyzer processes DO statements.
Each WHEN block has a single or compound WHEN statement and one or more DO statements associated
with it. The search is conducted as follows:
 Control-M/Analyzer searches for the string specified by the first (highest) WHEN statement of the
WHEN block.
If the string is not found, the WHEN block, including its DO statements, are skipped and rule
processing continues.
If the string is found (for example, the WHEN criteria are met), the current position is set to the
position of the first character of the located string in the data source. This position is stored for every
WHEN statement and can be referenced by the LEVEL parameter in a DO EXTRACT statement.
Control-M/Analyzer then searches for the string specified by the next WHEN statement of the current
WHEN block.

492
Control-M/Analyzer User Guide

 If the ON statement MODE parameter is set to PG (page mode) and the search area for the string
specified by the next WHEN statement is defined with absolute line numbers, Control-M/Analyzer will
search for that string on the current page and on each subsequent page of the dataset.
Note: If there are two or more compound WHEN statements, after the first has been found, the
search continues for the next WHEN, and so on. The process is repeated for each page.
 The search continues in this manner. Subsequent WHEN statements are evaluated only after the
requirements of higher WHEN statements in the block have been met.
 If all the criteria of all specified statements of the current WHEN block are met, the DO statements of
that WHEN block are performed.
After performing the DO statements, Control-M/Analyzer continues to search for the string specified in
the last (lowest) WHEN statement. Each time the string is found, the DO statements are performed
again.
Note: If only one WHEN statement exists in the block, it is considered the last. Therefore, it is
searched for repeatedly. Each time its criteria are met, the DO statements are performed. If the
EXECUTE block consists of several WHEN blocks, the WHEN blocks are executed in parallel and
independently of each other. This enables the simultaneous search for unrelated criteria in the same
data.
Example 1
A large company is divided into several departments. Each department contains many employees. A
report exists that is grouped by department. Within each department, employees and corresponding
salary information are listed in alphabetical order.
Figure 280 Data for WHEN Structure – Example 1
COMPUTER ENTERPRISES, INC. 05/05/00 PAGE: 1

DEPT. NO DEPT. TITLE


/EMP. NO /EMP. NAME START SALARY
============================================================================
001 MARKETING DEPARTMENT
-----------------------------------
002201 GRANT, THOMAS 04/09/96 40,000
002015 JAMES, KAREN 02/01/97 45,000
001839 JONES, BARRY 03/08/94 36,000
002345 ROBERTSON, JANE 03/10/99 20,000
020 ACCOUNTING DEPARTMENT
------------------------------------
002154 JONES, BOB 04/11/98 35,000
001454 SMITH, BARBARA 02/02/00 45,000
002002 WILLIAMS, SALLY 01/10/99 35,000

The salary information for an employee named Jones in the accounting department is desired. A
compound WHEN statement is specified:

493
Control-M/Analyzer User Guide

Table 271 Compound WHEN Statement for WHEN Structure – Example 1

WHEN Statement Level


Number String to Search for STOP String

1 ACCOUNTING BRANCH:

2 JONES

STOP Criteria
After DO statements of a WHEN block are performed, the search continues for the last (lowest) WHEN
statement.
STOP criteria provide a means to restart searches from higher level WHEN statements (of the current
WHEN block).
If the criteria of a WHEN statement are met, Control-M/Analyzer searches for the STOP criteria specified
in that WHEN statement. This search begins on the next line after the line containing the WHEN
statement criteria.
If the STOP criteria are not met, processing continues as described in "Compound WHEN Statements"
above.
If the STOP criteria are met, Control-M/Analyzer stops searching for strings specified by lower WHEN
statements and resumes searching for the string specified in the WHEN statement whose STOP criteria
were met. This search begins with the line containing the STOP criteria.
Example 2
A large restaurant chain has several branches. Each branch employs several individuals. A report exists
that is grouped by branch. Each branch name is preceded by the string BRANCH:. Within each branch,
employees and their salary information are listed. Each employee name is preceded by the string
EMPLOYEE:.
Figure 281 Data for WHEN Structure – Example 2
FAST-FOOD, INC. 05/05/00 PAGE:51
==============================================================================
BRANCH: MIAMI BEACH
------------------------------------------------------------------------------
EMPLOYEE: GRANT, THOMAS 04/09/96 40,000
EMPLOYEE: JAMES, KAREN 02/01/97 45,000
EMPLOYEE: JONES, BARRY 03/08/94 36,000
EMPLOYEE: ROBERTSON, JANE 03/10/99 20,000

BRANCH: NEW YORK CITY


------------------------------------------------------------------------------
EMPLOYEE: JONES, BOB 04/11/98 35,000
EMPLOYEE: SMITH, BARBARA 02/02/00 45,000
EMPLOYEE: WILLIAMS, SALLY 01/10/99 35,000

BRANCH: PHILADELPHIA
------------------------------------------------------------------------------
EMPLOYEE: MCPHEARSON, BRIAN 10/10/98 25,000
EMPLOYEE: PETERS, KEITH 04/04/97 50,000

Salary information for all employees of the New York City branch is desired. STOP criteria are specified
within a compound WHEN statement:

494
Control-M/Analyzer User Guide

Table 272 Compound WHEN Statement for WHEN Structure – Example 2

WHEN Statement Level


Number String to Search for STOP String

1 NEW YORK CITY BRANCH:

2 EMPLOYEE:

Search Areas (LINE and COL Parameters)


The LINE and COL parameters delimit the upper left and lower right corners of the area to be searched.
This area is called a Search area. When Control-M/Analyzer scans the data source line by line for the
specified STRING, only lines and columns within the Search area are examined.
When a string is specified without a comparison operator (.GT., .LT., .GE., .LE., or .NE.), the entire Search
area is examined. However, when a string (or another string to which it is joined by a Boolean operator)
is specified with a comparison operator, only the beginning of the Search area (starting at FROM COL with
a length equal to the number of characters in the specified string) is examined. For more information on
these topics see "Comparison Operators" and "Boolean Operators" above.
Note: The start of the page is determined by machine or ASA codes, if available, or by page length
definition and line counting.
LINE and COL can contain the following types of values:

495
Control-M/Analyzer User Guide

Table 273 WHEN Structure LINE and COLUMN Values

Value Description

Absolute Values Explicit line numbers (based on the start of the dataset or the start
of the current page, depending on the MODE), and explicit column
numbers.
Example
WHEN LINE 003-020 COL 050-070
The ON statement MODE parameter specifies whether Absolute
Values are based on the start of the dataset or the start of the
page. Line and column number prefixes can be specified to
override the default set by MODE. (See "Relative Values" and
"WHEN Relative Values" below.)
See Compound WHEN Statements (on page 492) for information
about how the search process is performed when the MODE
parameter is set to PG and absolute line numbers are specified in
the LINE parameter.

Relative Values Relative line numbers can be specified with the following prefixes:
 PG+n – n lines after the beginning of the current page.
 PG-n – n lines before the beginning of the current page.
 DS+n – n lines after the beginning of the current dataset.
Examples
WHEN LINE PG+003 - PG+020 COL 050 - 070
WHEN LINE DS+003 - DS+020 COL 050 - 070

496
Control-M/Analyzer User Guide

Value Description

WHEN Relative Values Line and column numbers can be relative to the location where a
search string, specified by a higher level WHEN statement, was
found. The higher level WHEN, whose criteria were met, must be
within the same WHEN block as the specified relative LINE and
COL values.
Because several WHEN statements may exist within the same
WHEN block, the desired WHEN statement level must be identified.
Each WHEN is numbered in ascending order (indicated by m in the
format below), beginning with the number one. (Level zero cannot
be specified in statement WHEN.)
The appropriate WHEN statement can be referenced by specifying
the hierarchical level using the following prefixes:
 Lm+n – n lines after the position located by the WHEN of level
m.
 Lm-n – n lines before the position located by the WHEN of
level m.
 Cm+n – n columns after (to the right of) the position located
by the WHEN of level m.
 Cm-n – n columns before (to the left of) the position located
by the WHEN of level m.
These prefixes cannot be used to refer to WHEN statements of
other WHEN blocks. However, these prefixes can be used in the
STOP criteria for the same WHEN block.
Examples
WHEN LINE L01+003 - L01+020 COL 050 - 070
WHEN LINE 003 - 020 COL C01+050 - C01+070

Note: When working in MODE=DS (dataset), line number "999" denotes the end of the report (for
example, LINE 001-999 means all lines of the report).
It is possible to reference a string a few pages prior to the current page by using negative numbers. The
number of pages retained (kept) for this purpose is set in the RTEBUF installation parameter. For
additional information, see the discussion about installing Control-M/Analyzer in the INCONTROL for z/OS
Installation Guide.
The search for STOP criteria always begins on the line after the line where the corresponding WHEN
criteria were found, even if the STOP LINE parameter specifies a prior line.
STRING Operators
A string must be specified when no operator is used and immediately after each .GT., .LT., .GE., .LE.,
.NE., and .WI. operator.
The string for operator .WI. is a mask containing one or more ? symbols. Each ? represents a single "wild
character" that may be a number, letter or symbol. For example, ??/??/?? can be used as the mask for a
date in this format.

497
Control-M/Analyzer User Guide

Operator .AL. instructs Control-M/Analyzer to perform subsequent DO statements for every line in the
LINE/COL range (as if every line matched the WHEN criteria, without regard to the string). No string is
searched for or compared. Therefore, no string is specified. However, the position found in the line is
automatically set to the FROM column value (the first value in the COL range). For subsequent DO
EXTRACT statements, the position within the line found as a result of using operator .AL. is 1.
Operators .SR. and .ER. instruct Control-M/Analyzer to perform subsequent DO statements once at the
start or end of the report (as if the first or last line of the report matched the WHEN criteria, without
regard to the string). No string is searched for or compared; therefore, no string is specified.
Operators .SP. and .EP. instruct Control-M/Analyzer to perform subsequent DO statements at the start or
end of each page (as if the start or end of each page matched the WHEN criteria, without regard to the
string). No string is searched for or compared. Therefore, no string is specified.
AutoEdit Substitution
Control-M/Analyzer AutoEdit and Local variables can be embedded in WHEN and STOP criteria. The
variables are resolved (replaced) at time of rule execution. For additional information on AutoEdit
processing see Control-M/Analyzer Variables (on page 222).
Single vs. Multiple Occurrences of a String
System variable SYSSRCHALL determines whether a line will be searched for all occurrences or for only
the first occurrence of the string specified in a WHEN statement. When SYSSRCHALL=0 (the default
value), only the first occurrence on a line is found. When SYSSRCHALL=1, the search continues until
every occurrence on the line has been found and the DO statements are performed each time an
occurrence is found. See Summary of System Variables (on page 262) for a description of this system
variable.
Example 3
The report printed below illustrates the uses of statement WHEN. For each salesperson, the report lists
invoiced sales and year-to-date totals for sales, commissions paid, commissions owed, and the
commission payroll amount.
The report is formatted as follows:
 Year-to-date commissions paid for each salesperson are located between columns 68 and 78, and are
preceded by the phrase YTD COMMISSIONS PAID.
 For each salesperson, the figure (in the same column range) directly below the year-to-date
commissions paid represents the year-to-date commissions owed.
 For each salesperson, the figure (in the same column range) two lines below the year-to-date
commissions paid represents the commission payroll amount.
Note: A column numbering line has been provided at the top and bottom of the sample report for your
convenience. This line is not an actual report line.

498
Control-M/Analyzer User Guide

Figure 282 Data for WHEN Structure – Example 3


-+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+-
INTRAC INC. SALES OPERATIONS DEPARTMENT DATE 28/04/00 TIME 23:50 PAGE 1
S A L E S C O M M I S S I O N S D E T A I L FROM 01/01/99 TO 30/04/99
SALESPERSON HARVEY J. JONES (197)| INVOICE # | INVOICE DATE| AMOUNT | STATUS
+--------------------------------------------------------------------------------------------
| CJ39394 | 02/02/00 | 2040.00 |COLLECTION|
| CJ98443 | 03/03/00 | 245.00 | |
| MJ24545 | 05/04/00 | 10344.40 | |
| RJ10030 | 01/02/00 | 5329.39 | |
| RJ12233 | 02/02/00 | 5000.00 | |
| RJ30021 | 03/02/00 | 16670.10 | |
| RJ32991 | 02/03/00 | 30300.44 | |
| RJ33939 | 03/03/00 | 900.25 | |
| RJ38001 | 05/04/00 | 1000.23 | |
| RJ93043 | 06/04/00 | 415.89 | |
+--------------------------------------------------------------------------------------------
TOTAL SALES - THIS MONTH 72245.70 |PAID IN FULL
ADJUSTMENTS -5800.70
YTD SALES (INCLUDING THIS MONTH) -127879.00
YTD COMMISSIONS PAID 0.00
YTD COMMISSIONS OWED -5115.00
COMMISSION PAYROLL AMOUNT 5115.00
-+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+-

Year-to-date commissions paid, year-to-date commissions owed, and commission payroll amount for each
salesperson are extracted from this report. These numbers are compared to determine if the data in the
report are balanced.
The string YTD COMMISSIONS PAID is found once for each salesperson in the report. Each time the string
is found, the DO EXTRACT statement extracts the three commission figures. For each salesperson, the
sum of the year-to-date commissions paid and the commission payroll amount should equal the
year-to-date commissions owed. This formula indicates whether the figures are balanced.
Figure 283 WHEN Structure – Example 3
LIBRARY : CTB.PROD.RULES RULE : ARWARN02
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
EXECUTE INPUT UPON C
ON SYSOUT PROCST PGMST STEP01 DDNAME SYSUT2 JOBNM
MODE PG LINECT 0000 DATASTAMP
WHEN LINE 001 - 060 COL 001 - 025 STOP AND/OR
STRING = YTD COMMISSIONS PAID
DO EXTRACT = YTDPAID
LEVEL 0 LINE +000 COL 0068 - 0078 PROCESS TYP
DO EXTRACT = YTDOWED
LEVEL 0 LINE +001 COL 0068 - 0078 PROCESS TYP
DO EXTRACT = CURRENT
LEVEL 0 LINE +002 COL 0068 - 0078 PROCESS TYP
DO BLOCK = CHECK ARG C
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE ENDJOB UPON C
ON DATA
IF ERRORCOUNT>0 C
DO PRINT = %%BLANK F C
PLEASE FILL IN RULE DEFINITION. 14.58.28

499
Control-M/Analyzer User Guide

Example 4
A sysout of a report is provided below to illustrate the uses of statement WHEN. The report shows a
sample banking statement with fields for check number, account number, bank number, transaction date,
and transaction amount.
Every debit line begins with D.
Every credit line begins with C.
Note: Column numbering lines have been provided at the top and the bottom of the sample report for
your convenience. These lines are not actual report lines.
Figure 284 Data for WHEN Structure – Example 4
----+----1----+----2----+----3----+----4----+----5----
D 0001042 4489/54 663 05/04/00 + 5000.00
C 0001231 6297/53 660 09/10/00 + 250.00
D 0000411 3242/32 659 07/08/00 + 10500.50
C 0000012 4487/34 659 05/06/00 + 670.24
C 0001333 8834/18 663 12/10/00 + 1000.45
C 0001031 3233/10 663 12/12/00 + 1000450.75
C 0001173 3233/32 659 05/10/00 - 150.00
D 0001122 4353/01 663 05/10/00 + 904.99
C 0000099 1252/10 659 06/04/00 - 100.80
D 0001050 3341/33 663 05/01/00 - 350.55
D 0001283 9893/34 663 26/05/00 - 50.00
D 0001001 1234/56 660 18/05/00 + 3000.00
D 0001023 3422/39 663 10/08/00 + 250.25
C 0000835 4200/10 663 05/05/00 - 250.25
D 0001560 2229/09 660 08/12/00 + 2000000.00
----+----1----+----2----+----3----+----4----+----5----

Each line that starts with C is located and all the credits are added to Database variable DB_CREDIT. Each
line that starts with D is located and all the debits are added to Database variable DB_DEBIT. Summation
is performed during the extraction because the TYP parameter is set to SU.
Figure 285 WHEN Structure – Example 4
LIBRARY : CTB.PROD.RULES RULE : BANKSTAT
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M43 GROUP BANKING
UPDATED 08/08/00 - 15:17:14 BY M43A
DESC TOTAL CREDITS AND DEBITS OF BANK STATEMENT
OPTIONS
===========================================================================
EXECUTE GETOWED UPON C
ON SYSOUT PROCST PGMST STEP12 DDNAME ACCREP JOBNM
MODE DS LINECT 0000 DATASTAMP
WHEN LINE 001 - 999 COL 002 - 002 STOP AND/OR
STRING = C
DO EXTRACT = DB_CREDIT
LEVEL LINE +000 COL 0004 - 0010 PROCESS TYP SU
DO
WHEN LINE 001 - 999 COL 002 - 002 STOP AND/OR
STRING = D
DO EXTRACT = DB_DEBIT
LEVEL LINE +000 COL 0004 - 0010 PROCESS TYP SU
DO
WHEN LINE - COL - STOP AND/OR
STRING =
PLEASE FILL IN RULE DEFINITION. 15.21.56

The report on the following page illustrates additional uses of statement WHEN. The report shows the
status of accounts receivable for a company. It is formatted as follows:

500
Control-M/Analyzer User Guide

 Every account starts on a new page. An account may span several pages. In this case, the word
CONTINUED appears in the STATUS column at the bottom of each page (except the last) for that
account.
 If an account has an outstanding balance, the balance is printed after the words TOTAL DUE:. If the
account has no outstanding balance, the words PAID IN FULL are displayed instead.
 The page number is printed at the top of each page, prefixed by the word PAGE. There is a maximum
of 60 lines on each page.
 Each line of the report starts in column two. (The first column is reserved for ASA-code control
character symbols.)
Note: Column numbering lines have been provided at the top and the bottom of the sample report for
your convenience. These lines are not actual report lines.

501
Control-M/Analyzer User Guide

Examples 5, 6 and 7 are based on this sample report.


Figure 286 Data for WHEN Structure – Examples 5, 6, and 7
---+----1----+----2----+----3--——+----4----+----5----+----6----+----7----+----8----+----9----
ACCOUNTS RECEIVABLE DEPARTMENT DATE 28/12/99 PAGE 000001

C L I E N T H I S T O R Y D E T A I L FROM 01/01/99 TO 05/05/99


|ACCOUNT MAIN ACCOUNTING CONS. (MAC) |INVOICE|INVOICE DATE|AMOUNT |AMOUNT DUE|STATUS
+--------------------------------------------------------------------------------------------
| |CJ98443| 03/03/99 | 245.00| 0.00 |
| |MJ24545| 05/04/99 |10344.40| 0.00 |
| |RJ10030| 01/02/99 | 5329.39| 0.00 |
| |RJ12233| 02/02/99 | 5000.00| 0.00 |
| |RJ30021| 03/02/99 |16670.10| 0.00 |
| |RJ32991| 02/03/99 |30300.44| 0.00 |
| |RJ33939| 03/03/99 | 900.25| 0.00 |
| |RJ38001| 05/04/99 | 1000.23| 0.00 |
| |RJ93043| 05/04/99 | 415.89| 0.00 |
+--------------------------------------------------------------------------------------------
| TOTALS | | |70205.70| 0.00 | PAID IN FULL

ACCOUNTS RECEIVABLE DEPARTMENT DATE 28/12/99 PAGE 000002

C L I E N T H I S T O R Y D E T A I L FROM 01/01/99 TO 05/05/99


|ACCOUNT GENERAL COMP. SYSTEMS (GCS)|INVOICE|INVOICE DATE|AMOUNT |AMOUNT DUE|STATUS
+--------------------------------------------------------------------------------------------
| | 100322| 02/01/99 | 1000.00| 1000.00|
| | 100400| 02/01/99 | 500.00| 500.00|
| | 100405| 02/01/99 | 500.00| 500.00|
| | 100520| 02/02/99 | 333.34| 333.34|
| | 100560| 02/02/99 | 3000.00| 3000.00|
| | 100561| 02/02/99 | 250.00| 250.00|

| | 100678| 02/02/99 | 1000.00| 1000.00|


| | 200001| 01/03/99 | 250.00| 250.00|
| | 200012| 01/03/99 | 333.33| 333.33|
| | 200300| 01/04/99 | 500.00| 500.00|
| | 200456| 01/04/99 | 500.00| 500.00|
| | 202533| 05/04/99 | 1000.00| 1000.00|
| | 300003| 12/04/99 | 250.00| 250.00|
| | 340203| 26/04/99 | 333.33| 333.33|
+--------------------------------------------------------------------------------------------
| | | | | |CONTINUE

ACCOUNTS RECEIVABLE DEPARTMENT PAGE 000003

C L I E N T H I S T O R Y D E T A I L FROM 01/01/99 TO 05/05/99


|ACCOUNT GENERAL COMP. SYSTEMS (GCS)|INVOICE|INVOICE DATE|AMOUNT |AMOUNT DUE|STATUS
+--------------------------------------------------------------------------------------------
| | 343211| 26/04/99 | 500.00| 500.00 |CONTINUED
| | 350032| 04/05/99 | 1000.00| 1000.00 |
| | 520033| 05/05/99 | 500.00| 500.00 |
| | 540050| 05/05/99 | 2000.00| 2000.00 |
| | 540051| 05/05/99 | 1000.00| 1000.00 |
| | 540052| 05/05/99 | 250.00| 250.00 |
+--------------------------------------------------------------------------------------------
| TOTALS | | |15000.00| 15000.00 | TOTAL DUE:
15000.00

ACCOUNTS RECEIVABLE DEPARTMENT DATE 28/12/99 PAGE 000004

C L I E N T H I S T O R Y D E T A I L FROM 01/01/99 TO 05/05/99


|ACCOUNT NATIONAL BANK |INVOICE |INVOICE DATE|AMOUNT |AMOUNT DUE|STATUS
+--------------------------------------------------------------------------------------------
| |B7003003| 02/02/99 | 1800.00| 300.00|
| |B7003420| 03/03/99 | 2700.00| 2700.00|
| |B7004009| 05/04/99 | 1500.00| 1500.00|
| |B7018700| 05/05/99 | 500.00| 500.00|
+--------------------------------------------------------------------------------------------
| TOTALS | | | 5000.00| 5000.00| TOTAL DUE:
300.00
---+----1----+----2----+----3--——+----4----+----5----+----6----+----7----+----8----+----9----

502
Control-M/Analyzer User Guide

Example 5
The financial status of client General Comp. Systems (GCS) is determined.
Two WHEN statements, logically connected by the AND parameter, are specified. These two WHEN
statements form one compound WHEN statement.
 The first WHEN statement (level 1) initiates a search for the name of the company (string ‘GENERAL
COMP. SYSTEMS (GCS)’) on line four of each report page.
 The second WHEN statement (level 2) locates the totals line of the report for this company (string
‘TOTALS’) that appears on the current page or subsequent page of the report.
When both strings are located, the DO statements in this WHEN block are processed. In this example, the
DO statements are executed only once. Control-M/Analyzer does not continue searching for string
TOTALS because the last DO statement specified is DO TERMINAT.
Figure 287 WHEN Structure – Example 5
LIBRARY : CTB.PROD.RULES RULE : GCSSTAT
COMMAND ===> SCROLL===> CRSR
+-------------------------------------------------------------------------------+
======= >>>>>>>>>>>>>>> TOP OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =======
OWNER M18B GROUP ACCOUNTS
UPDATED 09/09/99 - 15:30:05 BY M18B
DESC REPORT THE STATUS OF GENERAL COMP. SYSTEMS
OPTIONS
=============================================================================
EXECUTE REPGCS UPON C
ON SYSOUT PROCST PGMST STEP01 DDNAME SYSUT2 JOBNM
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 004 - 004 COL 002 - 050 STOP AND/OR A
STRING = ACCOUNT GENERAL COMP. SYSTEMS (GCS)
WHEN LINE 006 - 060 COL 002 - 010 STOP AND/OR
STRING = TOTALS
DO EXTRACT = NAME
LEVEL 1 LINE +000 COL +008 - +034 PROCESS TYP
DO EXTRACT = STATUS
LEVEL 2 LINE +000 COL +092 - +116 PROCESS TYP
DO PRINT = STATUS OF COMPANY %%NAME F C
DO PRINT = IS %%STATUS F C
DO TERMINAT = OK COD 0000
PLEASE FILL IN RULE DEFINITION. 12.23.19

503
Control-M/Analyzer User Guide

Example 6
Building on the previous example, a summary report (that provides a list of company names and their
financial status) is created.
Two WHEN statements, that are similar to the WHENs of the previous example, are specified. In this
example, the search for a new client should resume each time a new page is reached (because each
client starts on a new page). STOP criteria are added to the highest WHEN. These STOP criteria search
for operator .SP. (start of page) that identifies a new page.
As a result of this definition, Control-M/Analyzer searches for the string ACCOUNT again on every new
page. Control-M/Analyzer finds the name of the current client, and locates the string TOTALS until the
end of the report is reached.
Figure 288 WHEN Structure – Example 6
LIBRARY : CTB.PROD.RULES RULE : SUMREP
COMMAND ===> SCROLL===> CRSR
+------------------------------------------------------------------------------+
OWNER M18B GROUP ACCOUNTS
UPDATED 09/09/99 - 15:30:05 BY M18B
DESC SUMMARIZE THE ORIGINAL REPORT
OPTIONS
============================================================================
EXECUTE REPORT UPON C
ON SYSOUT PROCST PGMST STEP01 DDNAME SYSUT2 JOBNM
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 004 - 004 COL 002 - 015 STOP Y AND/OR A
STRING = ACCOUNT
STOP LINE 001 - 006 COL 002 - 010
STRING = .SP.
WHEN LINE 006 - 060 COL 002 - 015 STOP AND/OR
STRING = TOTALS
DO EXTRACT = NAME
LEVEL 1 LINE +000 COL +008 - +034 PROCESS TYP
DO EXTRACT = STATUS
LEVEL 2 LINE +000 COL +092 - +116 PROCESS TYP
DO PRINT = %%NAME-%%STATUS F C
DO
PLEASE FILL IN RULE DEFINITION. 14.43.36

504
Control-M/Analyzer User Guide

Example 7
The average invoice amount for each company is calculated by specifying three WHEN statements,
connected by AND parameters. The first two WHEN statements specify STOP criteria. These three WHEN
statements form one WHEN block.
 The first WHEN statement determines starting and ending lines for each company. The average of
each company is retrieved from the lines located between the company name and TOTALS.
 The second WHEN statement determines which lines (of the lines located by the first WHEN) contain
a total that should be extracted. In the report, these lines are located between two lines of dashes
(these lines contain a numeric value in column AMOUNT).
The third WHEN statement locates the actual invoice amounts. Control-M/Analyzer retrieves amounts
from exactly one line after the first line of dashes. Processing finishes when the second line of dashes is
reached.
Figure 289 WHEN Structure – Example 7
LIBRARY : CTB.PROD.RULES RULE : AVERAGES
COMMAND ===> SCROLL===> CRSR
+------------------------------------------------------------------------------+
EXECUTE CALCAVG UPON C
ON SYSOUT PROCST PGMST STEP01 DDNAME SYSUT2 JOBNM
MODE PG LINECT 0060 DATASTAMP
WHEN LINE 005 - 005 COL 002 - 011 STOP Y AND/OR A
STRING = ACCOUNT
STOP LINE 006 - 060 COL 002 - 015
STRING = TOTALS
WHEN LINE 006 - 060 COL 001 - 020 STOP Y AND/OR A
STRING = ————
STOP LINE 007 - 060 COL 001 - 020
STRING = ————
WHEN LINE L02+001 - 060 COL 070 - 081 STOP AND/OR
STRING = .AL.
DO EXTRACT = FULLNAME
LEVEL 1 LINE +000 COL +008 - +034 PROCESS TYP
DO EXTRACT = SHRTNAME
LEVEL 1 LINE +000 COL +031 - +033 PROCESS TYP
DO BLOCK = CHKNAME ARG SHRTNAME,FULLNAME
DO EXTRACT = AVG%%SHRTNAME C
LEVEL 0 LINE +000 COL +000 - +011 PROCESS TYP AV
PLEASE FILL IN RULE DEFINITION. 14.09.00

Example 8
The input for this example is a bank customer report. The account balance (variable AMOUNT) is
extracted from "detail lines" that contain a ‘C’ (for Credit) or ‘D’ (for Debit) in column 2. The extracted
quantities are summed by record type (C or D). The detail lines can be identified and the account balance
can be extracted and summed with one WHEN statement.
The DO EXTRACT statements illustrated below first extract the record type (C or D), and then sum the
AMOUNT by record type. This is done by dynamically incorporating the record type (C or D) as part of the
variable name (AMOUNT%%TYPE).

505
Control-M/Analyzer User Guide

Figure 290 WHEN Structure – Example 8


LIBRARY : CTB.ALL.RULES RULE : WHEN01
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M55 GROUP INTRAC
UPDATED 08/08/00 - 17:45:92 BY M55
DESC COMPOUND WHEN CRITERIA
OPTIONS
===========================================================================
EXECUTE INPUT UPON C
ON SYSOUT PROCST PGMST DDNAME BANKREP JOBNM
MODE PG LINECT DATASTAMP
WHEN LINE 001 -060 COL - 002 - 002 STOP AND/OR
STRING = C.OR.D
DO EXTRACT = TYPE
LEVEL 0 LINE +000 COL 0002 - 0002 PROCESS TYP
DO EXTRACT = AMOUNT%%TYPE
LEVEL LINE +000 COL 0060 - 0070 PROCESS BFNUM TYP SU
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE UPON C
PLEASE FILL IN RULE DEFINITION. 17.47.18

Example 9
The input for this example is an employee report. The employee number, salary and vacation days are
extracted from detail lines that contain any digit in column 9. (Column 9 contains the first digit of the
employee number.)
The required operations can be accomplished with one WHEN statement. The WHEN statement searches
for any character that is less than or equal to 9 and greater than or equal to zero.
Figure 291 WHEN Structure – Example 9
LIBRARY : CTB.ALL.RULES RULE : WHEN01
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M55 GROUP INTRAC
UPDATED 08/08/00 - 17:45:92 BY M55
DESC COMPOUND WHEN CRITERIA
OPTIONS
===========================================================================
EXECUTE INPUT UPON C
ON SYSOUT PROCST PGMST DDNAME BANKREP JOBNM
MODE PG LINECT DATASTAMP
WHEN LINE 001 - 060 COL 009 - 009 STOP AND/OR
STRING = .LT.9 .AND. .GT.0
DO EXTRACT = EMP_NUM
LEVEL 0 LINE +000 COL 0009 - 0019 PROCESS TYP
DO EXTRACT = SALARY
LEVEL LINE +000 COL 0060 - 0070 PROCESS TYP
DO EXTRACT = VACATION
LEVEL LINE +000 COL 0050 - 0055 PROCESS TYP
DO BLOCK = CHECK ARG C
DO
WHEN LINE - COL - STOP AND/OR
STRING =
PLEASE FILL IN RULE DEFINITION. 17.47.18

506
Control-M/Analyzer User Guide

Rule Definition Using an Editor


Two methods exist for defining Control-M/Analyzer balancing rules:
 Online Rule Definition
Balancing criteria are specified as parameters in the fill-in-the-blanks Rule Definition screen of the
Online facility. This method of communicating with Control-M/Analyzer makes rule definition quick and
easy, especially for novice users. Refer to Appendix A and the parameter descriptions in this chapter
for additional information.
 Rule Definition Using a Standard Editor
Rules can be created and modified directly using a standard editor (for example, ISPF/EDIT).
Commands are typed into a member in a format consistent with the Control-M/Analyzer Rule
Definition language and syntax. See "Language Syntax" and "Command Reference" in this chapter for
additional information.
Rule Definitions are stored as members in standard user libraries. Rule Definitions are stored in the same
format regardless of definition method. Therefore, rules defined using the Online facility may be modified
using a standard editor. Rules defined using a standard editor may be modified using the Online facility.
The following pages present an overview of the process for creating Rule Definitions using a standard
editor. The Control-M/Analyzer Rule Definition language and syntax are described. Examples of Rule
Definitions (as viewed in an editor) are provided.
Control-M/Analyzer Rule Definition language commands correspond directly to Online Rule Definition
parameters. A quick reference of language commands is provided in this chapter. For more detailed
information relating to a language command, refer to its corresponding parameter in this chapter.

Working with Rules Created with an Editor


Control-M/Analyzer provides the ability to create rule definitions in PDS library members with a standard
editor. BMC recommends this method for the experienced user who prefers using a familiar editor and
does not need the guidance provided by the Online facility.
The Online facility validates parameter specifications, automatically creating rule definitions that are
syntactically correct. In contrast, rule definitions created with a standard editor may not conform to the
Rule Definition language. Therefore, BMC recommends that a validity check be performed on rules
created with a standard editor.
The experienced user who wants to quickly create a valid rule should perform the following two steps:
 Create the rule
Use a standard editor to define the rule. The rule definition must conform to Control-M/Analyzer rule
definition language and syntax requirements.
 Check the syntax of the rule
Use one of the methods described on the following page to perform syntax checking and error
flagging.
This iterative process (writing, checking, and correcting the rule until no errors exist) is similar to program
development using high level programming languages.

507
Control-M/Analyzer User Guide

Syntax Checking
The following methods exist for checking the syntax of rule definitions:
 Through the Online facility
Rule definitions viewed using the Online facility are automatically checked for syntax errors. Syntax
error messages are displayed in a special error message screen. Additional changes cannot be made
to a rule with a syntax error until the error is corrected.
 Through the Control-M/Analyzer Runtime Environment
When the Control-M/Analyzer Runtime Environment is invoked, rule definitions are automatically
checked for syntax errors. Results are displayed in the SYSPRINT job output.
 Through utility CTBCMP
Utility CTBCMP checks the syntax of the specified rule definition. For additional information about this
utility, see the INCONTROL for z/OS Utilities Guide.
 Quick Compile program module CTBCQC
The rule definition can be checked for syntax errors while viewing the rule definition in a standard editor.
Specify !CTBCQC in the command field and press Enter. Results are inserted as note lines at the top of
the rule definition, as illustrated below:
Figure 292 Results of Quick Compile Program Module CTBCQC
EDIT ---- CTB.PROD.RULES(ARWARN02) - 01.00 ------------------- COLUMNS 001 072
COMMAND ==> SCROLL ===> CRSR
=NOTE= CONTROL-M/ANALYZER VERSION 6.0.00 RULE COMPILER
=NOTE=
=NOTE= CTB109I- COMPILATION STARTED
=NOTE= CTB110I- COMPILATION COMPLETED SUCCESSFULLY
=NOTE= CTB111I- HIGHEST ERROR CODE WAS 0
000001
000002 HEADER GROUP 'INTRAC' OWNER 'M66' DATE '090999' TIME '153005' CREATOR 'M
000003 66' DESC 'SUMMARIZE AND CHECK PAYROLL TOTALS'
000004
000005 EXECUTE 'INIT'
000006 ON_DATA
000007 ALWAYS
000008 DO SET 'ERRORCOUNT' EVAL '0'
000009 DO SET 'SLSNO' EVAL '0'
000010 DO SET 'BLANK' EVAL ''' '''
000011 DO PRINT DATA '******** PAYROLL CONTROL TOTALS ********'
000012

Rule Definition Structure


Each Control-M/Analyzer rule, regardless of definition method, is composed of header information and a
series of EXECUTE blocks. Each EXECUTE block specifies the data source to balance, data strings to
search for, and processing actions. An overview of the EXECUTE block structure is discussed earlier in this
chapter.
When defining a rule using a standard editor, the following information must be specified:
 Header information
Basic information about the rule, including the owner, group, and description of the rule.

508
Control-M/Analyzer User Guide

 EXECUTE blocks
A series of EXECUTE blocks, each specifying the data source that needs to be balanced, balancing
criteria, and resulting actions. Each EXECUTE block:
• Begins with command EXECUTE.
• Specifies a data source using command ON_.
• May identify data ranges to process using command WHEN.
• Performs actions specified by command DO.
EXECUTE blocks containing an ON DATA command are used to perform balancing actions on
Control-M/Analyzer variables. An IF-THEN-ELSE structure is used.
A sample rule definition structure is provided below:
Figure 293 Sample Rule Definition Structure
HEADER information

EXECUTE block name UPON execution criteria


ON_data source
WHEN criteria
DO processing statements
WHEN criteria
.
.
EXECUTE block name UPON execution criteria
ON_DATA
IF expression
DO processing statements
ELSE
DO processing statements
ALWAYS
DO processing statements
.
.
EXECUTE block name UPON execution criteria
ON_data source
WHEN criteria
DO processing statements
WHEN criteria
DO processing statements

509
Control-M/Analyzer User Guide

Language Syntax
 Commands, function names and System variable names are reserved words. These words should not
be specified as rule, mission, or variable names. For a complete list of reserved words, see B
Reserved Words (on page 673).
 A command line is processed from column 1 through 72. Columns 73-80 are ignored.
 A command may be continued from line to line if the end of a line is reached. If the end of a line is
reached in the middle of a specification in quotes (such as a data string specification), the
specification must continue in the first column of the next line.
 When typing the rule definition, BMC recommends that the text be indented to clearly indicate nesting
levels.
 Comments may be specified in the member by placing text between the symbols /* and */.
Comments are not processed during rule execution.
 Expressions may be specified to set the values of CONTROL variables. For syntax, see Expressions
and Functions (on page 269) and Database Variable Reference Method (on page 230).

Expression Delimiters
When creating rule definitions with the Online facility, quotes are automatically and appropriately placed
within the definition. When creating rule definitions with an editor, BMC recommends the manual insertion
of quotation marks.
Control-M/Analyzer recognizes two types of quotes:
Table 274 Control-M/Analyzer Expression Delimiters

Quote Description

Apostrophe ( ’ ) Used to delimit data strings or Control-M/Analyzer Expressions.

Consecutive Used to delimit data strings within Control-M/Analyzer Expressions.


apostrophes ( ’ ’ )

Variables and expressions whose operands are numeric do not need to be delimited by apostrophes:
IF SUM > 250 is equivalent to IF 'SUM > 250'
IF DB_TOTAL=TOTAL is equivalent to IF 'DB_TOTAL=TOTAL'
IF TOTAL=1000 is equivalent to IF 'TOTAL=1000'
Data strings must always be delimited:
DO PRINT 'DATA ARE BALANCED'
DO REMARK 'DATA ARE BALANCED'

If a data string exists within an expression, both the expression and the data string must be delimited.
The expression is delimited with apostrophes, and the data string is delimited with two consecutive
apostrophes (quotation marks).

510
Control-M/Analyzer User Guide

IF 'DB_EMPNAME = ''JONES'' '


DO SET GRADE EVAL ' '' A '' '

where A is a literal and not a variable name.


See Operands (on page 274) for examples of expressions that are and are not delimited by apostrophes.
BMC recommends that you do not specify Control-M/Analyzer reserved words within rule, mission, and
variable definitions. However, reserved words may be specified if enclosed between apostrophes:
DO RULE 'DATA'
ON_FILE 'FORM' ON_PARM MODE PG LINECT 60

Note: DATA and FORM – in the examples above – are reserved words. For a complete list of reserved
words, see B Reserved Words (on page 673).
AND is both an operator and a reserved word (as a parameter of statement WHEN). When specified as an
operator, AND must be placed between apostrophes along with the rest of the expression.
Valid:
IF 'DB_TOTAL < 1000 AND DB_TOTAL > 500'

Invalid:
IF 'DB_TOTAL < 1000' AND 'DB_TOTAL > 500'

Command Reference
The syntax and a brief description of each Control-M/Analyzer command is provided below. Each
command corresponds to an online Rule Definition parameter. The commands are grouped in the same
manner as the Online parameters: Basic Rule commands; Data Selection commands (ON_ commands);
Data Identification commands (WHEN, IF, ALWAYS); and DO commands (that are presented in
alphabetical order).
For additional information about a command, refer to the corresponding parameter or statement earlier in
this chapter.
Items enclosed in square brackets ([ ]) are optional. These items can be specified or omitted.

511
Control-M/Analyzer User Guide

Table 275 Control-M/Analyzer Commands

Command Syntax Description Options

ALWAYS [LABEL name] Unconditionally performs


a processing unit (only
ALWAYS
for ON_DATA).
Example
LABEL 'MUST'
ALWAYS
DO ...

DO ADDSYM DO ADDSYM Adds a variable to a new


var AutoEdit member or to
MEMSYM member an existing AutoEdit
LIBSYM library member read by
command DO GETMEM.
Example
DO ADDSYM VAR 'NEW_AE_VAR' MEMSYM
'$AESYMS'
LIBSYM 'M18.AE.LIB'

DO BLOCK DO BLOCK name Processes a different


[ARG arguments] EXECUTE block (of the
same rule) and
Example
optionally passes input
DO BLOCK 'CHECK' ARG 'SUM,AVG,COUNTER' and output arguments.
An argument is
referenced in the called
block by the BARG##
variable, where ## is
the two digit number
indicating the position of
the argument when
passed (for
example, BARG01,
BARG02, BARG03 ... ).

DO CALLUSER DO CALLUSER name Executes a user routine.


[ARG arguments]
Example
DO CALLUSER 'M18ROUT' ARG
'SUM,AVG,COUNTER'

512
Control-M/Analyzer User Guide

Command Syntax Description Options

DO COMMIT DO COMMIT Writes methods:


[VAR variable] Control-M/Analyzer ALL
method Database variables to NONE
the Database. If DO NOW
Examples
COMMIT is not specified INCLUDE
DO COMMIT VAR 'DB_FOREIGN.TOTAL' NOW in the rule, Database EXCLUDE
variables set during rule DELETE
DO COMMIT NONE
execution are committed
DO COMMIT VAR 'DB_FOREIGN.AVERAGE' at rule termination.
EXCLUDE
Options can be specified
to determine which
variables are committed,
and when.

DO COND DO COND condition Adds or deletes a opt:


ODATE dateref prerequisite condition to ADD
opt or from the IOA DEL
Conditions file.
Example
DO COND 'JOB_%%SYSJOBNAME_OK' ODATE
'0305' ADD

DO EXIT DO EXIT Immediately terminates


the current block.
Control passes to the
statement that called the
block if there is one.

DO EXTRACT DO EXTRACT variable Extracts data from a type:


LEVEL level data source and stores AV
LINE line the data in a SU
FCOL fcol Control-M/Analyzer
TCOL tcol variable. The extraction
[PROCESS process] is relative to the WHEN
[TYPE type] command of the
specified LEVEL.
Examples
This command cannot
DO EXTRACT 'CURRENT' LEVEL 0 LINE +0 FCOL
be used in EXECUTE
+10 TCOL +15
blocks that contain an
DO EXTRACT 'VEC%%I' LEVEL 0 LINE +0 FCOL ON_DATA command.
+10 TCOL +15
DO EXTRACT 'AVG' LEVEL 0 LINE +0 FCOL +10
TCOL +15 TYPE AV
DO EXTRACT 'SUM' LEVEL 0 LINE +0 FCOL +10
TCOL +15 TYPE SU

513
Control-M/Analyzer User Guide

Command Syntax Description Options

DO GETMEM DO GETMEM Retrieves an AutoEdit


MEMSYM member member and makes its
LIBSYM library AutoEdit symbols
available to the rule.
Example
DO GETMEM MEMSYM ‘$AESYMS’ LIBSYM
‘M18.AE.LIB’

DO GOTO DO GOTO Directs processing to


label-name statements in the
current block identified
Example
by label name.
DO GOTO 'CHECK' This command can only
be used in EXECUTE
blocks that contain an
ON_DATA command.

DO PRINT DO PRINT Prints a data string to


DATA data string the Control-M/Analyzer
Rule Activity report and
Example
to user files defined with
DO PRINT DATA 'THIS DATA WILL BE PRINTED the Dynamic Print
IN THE BANKING REPORT' facility.

DO PUTMEM DO PUTMEM Writes an AutoEdit


MEMSYM member member and its
LIBSYM library variables to the specified
library.
Example
DO PUTMEM MEMSYM '$AESYMS' LIBSYM
'M18.AE.LIB'

DO REMARK DO REMARK Adds a user-defined


DATA data string remark about the
Control-M/Analyzer
Example
invocation to the Rule
DO REMARK DATA 'THE DAILY SUM IS %%SUM' Activity report and the
Rule Activity display.

514
Control-M/Analyzer User Guide

Command Syntax Description Options

DO RULE DO RULE name Executes a different rule,


[ARG arguments] and optionally passes
input and output
Example
arguments to the rule.
DO RULE 'MYRULE' ARG 'SUM,AVG,COUNTER' An argument is
referenced in the called
block by the RARG##
variable, where ## is
the two digit number
indicating the position of
the argument when
passed (for
example, RARG01,
RARG02, RARG03 ...).

DO SET DO SET variable Initializes or modifies a


EVAL value Database, AutoEdit, or
Local variable.
Examples
DO SET 'I' EVAL '3'
DO SET 'STR' EVAL 'ABC'
DO SET '&&I' EVAL 'I*500'

DO SHOUT DO SHOUT Issues a message to a


MSG message TSO user, the operator
[URGENCY urgency] console, or the IOA Log
DEST destination file.
Examples
DO SHOUT MSG 'RULE RULFILE INITIALIZED'
URGENCY 'R' DEST 'TSO-M18'
DO SHOUT MSG 'MESSAGE TO OPERATOR'
URGENCY 'R' DEST 'OPER'

DO SYSOUT DO SYSOUT Specifies how a job


OPT processing option output should be
PRM class or destination handled.
FRM sysout class
Example
DO SYSOUT OPT C PRM B FRM X

515
Control-M/Analyzer User Guide

Command Syntax Description Options

DO TERMINATE DO TERMINATE Ends rule execution, result:


RESULT result specifying a result and a OK
USER_CODE user code user return code or NOTOK
abend code. TOLER
Examples
ABEND
DO TERMINATE RESULT OK
DO TERMINATE RESULT NOTOK USER_CODE
2222

EXECUTE EXECUTE block name Names the current


[UPON condition] EXECUTE block and
specifies any UPON
Example
criteria required for its
EXECUTE 'INPUT' UPON 'SYSJOBNAME NE execution.
M18CHKA'
This command must
always be followed by
command ON_.

HEADER HEADER Specifies basic


OWNER user id> information that
[CREATOR user id] describes the rule.
[GROUP group]
[DATE date]
[TIME time]
[DESC description]
Example
HEADER OWNER 'M18' CREATOR 'M18B'
GROUP 'FOREIGN-CURR' DATE '050599' TIME
'153005'
DESC 'FOREIGN CURRENCY BALANCING'

516
Control-M/Analyzer User Guide

Command Syntax Description Options

IF [LABEL name] Conditionally performs a


IF condition processing unit based on
[ELSE] Boolean logic (only for
ON_DATA).
Example
IF 'SUM GT 1000000' The IF condition is
DO ... evaluated. If true,
IF 'AVG GT 5000 AND AVG LT 10000' subsequent DO
DO... statements are
IF 'ISLEAP(YEAR)' performed. If false,
DO PRINT DATA %%YEAR IS A LEAP subsequent DO
YEAR' statements are skipped.
ELSE If ELSE is specified, the
DO PRINT DATA %%YEAR IS NOT A DO statements following
LEAP YEAR' the ELSE are performed
LABEL 'CHECK' when the IF condition
IF 'LENGTH(STR) GT 5' evaluates to false and
DO ... skipped when the IF
IF 'SUBSTR(STR,1,3) EQ ''ABC''' condition evaluates to
DO ... true.
LABEL 'ROOT1'
IF '(((-B)+SQRT(POW(B,2)-4*A*C))/(2*A)) GT 0'
DO ...

ON_CLASS ON_CLASS Examines sysouts MODE:


CLASS class created by the current DS
[EXTWTR extwtr] job, in a specified class, PG
[DEST destination] and (optionally) for a
DATA
[FORM] specified EXTWTR, DEST
STAMP:
[MODE mode] and FORM.
blank
[LINECT linect]
1
[DATASTAMP n]
2
Example
ON_CLASS CLASS 'X' DEST 'U2098' FORM 'STD'
EXTWRT 'SYS01'
ON_PARM MODE PG LINECT 6

ON_DATA ON_DATA Examines


Control-M/Analyzer
Example
variables.
ON_DATA

517
Control-M/Analyzer User Guide

Command Syntax Description Options

ON_DB2 ON_DB2 Indicates that the data MODE


SUBSYSTEM_ID subsystem to examine is from a DS
SQL_SELECT statement DB2 table. The dynamic PG
ON_PARM SQL facility is used to
DATA
[MODE mode] examine this data.
STAMP:
[LINECT linect]
blank
[DATASTAMP n]
1
Example 2
ON_DB2 SUBSYSYEM_ID ’X’ SQL_SELECT
’EMPNAME, EMPSALFROM EMPTABLE WHEN
EMPSAL>30000’ MODE PG LINECT 60

ON_DD ON_DD Examines a file MODE


DD ddname referenced by a specified DS
[MODE mode] DD statement of the PG
[LINECT linect] current step.
DATA
[DATASTAMP n]
STAMP:
Example blank
1
ON_DD DD 'MYDD' ON_PARM MODE PG LINECT
2
60

ON_DSN ON_DSN Examines a specified MODE:


CDAM criteria CDAM file. See CDAM in DS
(For Control-D
[MODE mode] the Control-D User PG
users only)
[LINECT linect] Guide.
DATA
[DATASTAMP i]
STAMP:
Example blank
1
ON_DSN
2
'LAST=YES,JOBNAME=M33CDMZ,DDNAME=$JES2
LOG,
PREFIX=D2PRSV' ON_PARM MODE PG LINECT 60

ON_FILE ON_FILE Examines a specified MODE:


FILE name sequential file. DS
[MODE mode] PG
[LINECT linect]
DATA
[DATASTAMP n]
STAMP:
Example blank
1
ON_FILE 'M18.SEQ.TEST' ON_PARM MODE PG
2
LINECT 60

518
Control-M/Analyzer User Guide

Command Syntax Description Options

ON_PAGE ON_PAGE Examines CDAM pages MODE:


[MODE mode] that have satisfied DS
(For Control-D
[LINECT linect] Control-D WHEN criteria. PG
users only)
[DATASTAMP n]
DATASTAM
Example P:
blank
ON_PAGE ON_PARM MODE PG LINECT 60
1
2

ON_ ON_SYSDATA Examines Control-M MODE:


SYSDATA [MODE mode] SYSDATA job sysouts DS
(For Control-M [LINECT linect] archived by PG
and Control-M [DATASTAMP n] Control-M/Restart.
DATASTAM
/Restart users
Example P:
only)
blank
ON_SYSDATA ON_PARM MODE PG LINECT 60
1
2

ON_SYSOUT ON_SYSOUT Examines a specified MODE:


DD ddname sysout previously DS
[PROC procstep] created by a step in the PG
[PGM pgmstep] specified job. If a job
DATA
[JOBNM job name] name is not specified,
STAMP:
[MODE mode] JOBNM defaults to the
blank
[LINECT linect] current job.
1
[DATASTAMP n]
2
Example
ON_SYSOUT DD 'SYSUT2' PROC 'STEP00'
PGM 'CTBREP' JOBNM 'ACTG1' ON_PARM MODE
PG LINECT 60

ON_VSAM ON_VSAM Examines a KSDS, RRDS


FILENAME dsn or ESDS type VSAM file.
[FIRSTKEY key / rba] Key can be specified for
[LASTKEY key / rba] KSDS files. rba can be
T ESDS / RRDS / KSDS specified for RRDS and
ESDS files.
Example
ON_VSAM FILENAME 'ACTG_INP' T 'RRDS'

519
Control-M/Analyzer User Guide

Command Syntax Description Options

WHEN WHEN Information required to prefix:


FLINE [prefix]±from line TLINE [prefix]±to conduct a string search DS
line on data (except for PG
FCOL [prefix]+-from col TCOL [prefix]±to col ON_DATA). L
SEARCH string C
[STOPWHEN prefix is an optional data
FLINE [prefix]±from line search reference point.
TLINE [prefix]±to line PG search starts at
FCOL [prefix]±from col beginning of the current
TCOL [prefix]±to col page. DS search starts
SEARCH string] at beginning of the
[AND/OR] dataset.
Examples
string can contain: .NE.,
WHEN FLINE 6 TLINE 7 FCOL 1 TCOL 100 .GE., .GT., .LE., or .LT.
SEARCH '.NE. SUNDAY'
from line, to line can be
WHEN FLINE 6 TLINE 7 FCOL 1 TCOL 100 absolute line numbers
SEARCH 'DEPT. A' (for example, 007, 009)
STOPWHEN FLINE 6 TLINE 7 FCOL 1 TCOL or relative line numbers
100 (for example, -2, +0)
SEARCH 'DEPT. B' defined as offsets from
AND current from line and
WHEN FLINE 12 TLINE 59 FCOL 6 TCOL 15 to line positions.
SEARCH 'DEBIT'
from col, to col can be
absolute line numbers
(for example, 025, 032)
or relative line numbers
(for example, -5, +2)
defined as offsets from
current from col and
to col positions.

520
Control-M/Analyzer User Guide

Rule Definition Process Examples


Below are three examples of the rule definition process.
Each example consists of three parts – a general overview of the purpose of the rule, a sample report,
and a rule definition.

Example 1
The sample sysout provided below lists account information for a banking institution.
 Header information is listed in lines 1 through 5. Account information is listed in lines 6 through 60.
 Each account number has a ‘/’ in column 8. This slash is used by the rule definition to determine if the
current line of the sysout contains information about a specific account. The deposit amount of each
account is specified in positions 92 through 103.
This rule definition calculates the sum of the deposit amount for all of the accounts. If the sum is greater
than 1,000,000, balancing criteria have not been met, a remark is specified, prerequisite condition
NOTOK-%%JOBNAME is added, and the rule is terminated with a NOTOK result.
Figure 294 Rule Definition Process Sample Report – Example 1
----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9---
FOREIGN CURRENCY DEPOSITS AS OF: 05/05/99
ACCOUNT DEPT NAME CURR DEPOSIT-PERIOD INTEREST INTEREST DEPOSIT MATURITY
NUMBER NO. ENCY TO FROM RATE AMOUNT AMOUNT DATE
000100/34 507 MURPHY CHRISTOPHER US 04/26/99 03/26/99 6.3570 9.15 7654321.99 05/26/99
000102/34 505 BRADY GREG US 04/26/99 03/25/99 7.3520 338.78 55296.50 06/25/99
000107/34 509 LOHEN ROBERT US 04/27/99 03/24/99 7.2910 40.04 6590.50 05/24/99
000110/34 507 KLINGNER KATHLEEN US 04/27/99 03/26/99 8.1130 13.39 1980.20 05/27/99
000112/34 420 SCHNEIDER ROBERT US 04/22/99 03/22/99 6.9220 45.13 7823.50 04/21/99
000118/34 310 BARNES THOMAS US 04/20/99 03/19/99 7.1430 93.86 15768.30 06/20/99
000121/34 512 BROWN ELIZABETH US 04/27/99 03/26/99 7.3520 10.44 1703.50 05/27/99
000125/34 505 KOTCH DIANA US 04/26/99 03/26/99 7.2910 102.01 16789.40 05/26/99
000129/34 512 KIRSTY JEFF US 04/27/99 03/25/99 7.3520 87.59 14296.50 05/27/99
000134/34 401 LIGMAN LEONARD US 04/27/99 03/25/99 7.1430 54.09 9087.70 06/27/99
000138/34 401 JENNY MICHAEL US 04/26/99 03/26/99 7.2910 53.44 8795.70 06/26/99
000140/34 310 BLAU CAROL US 04/26/99 03/25/99 6.9220 30.38 5267.50 04/25/99
000142/34 509 MARKS ANDREW US 04/22/99 03/22/99 6.5240 48.58 8935.50 04/21/99

521
Control-M/Analyzer User Guide

Figure 295 Rule Definition – Example 1


HEADER OWNER 'M18' CREATOR 'M18B' GROUP 'FOREIGN-CURR'
DATE '050599' TIME '153005'
DESC 'FOREIGN CURRENCY BALANCING'
/*
* EXAMINE THE SYSOUT ASSOCIATED WITH DDNAME SYSUT2, CREATED BY
* STEP STEP00/CTBREP IN THE CURRENT JOB.
* (THE SYSOUT CONTAINS THE REPORT LISTED ABOVE)
*/
EXECUTE 'INPUT'
ON_SYSOUT DD 'SYSUT2' PROC 'CTBREP' PGM 'STEP00'
/*
* PROCESS EACH LINE THAT HAS '/' IN POSITION 8
* (BUT ONLY LINES 6-60 OF EACH PAGE)
*/
WHEN FLINE +6 TLINE +60 FCOL +8 TCOL +9 SEARCH '/'
/*
* ACCUMULATE THE DATA IN COLUMNS 92-103 IN THE VARIABLE SUM
*/
DO EXTRACT 'SUM' LEVEL 0 LINE +0 FCOL +84 TCOL +95 TYPE SU
/*
* TAKE ACTIONS ACCORDING TO THE PREVIOUSLY COMPUTED SUM
*/
EXECUTE 'CHECK'
ON_DATA
ALWAYS
DO PRINT DATA 'TOTAL SUM IS : %%SUM'
IF 'SUM > 1000000.00'
DO SHOUT MSG 'PLEASE CHECK CURRENCY FILE; SUM COMPUTED IS %%SUM'
URGENCY 'R' DEST 'U-M18'
DO REMARK DATA 'SUM IS OVER 1000000: SUM=%%SUM'
DO COND 'NOTOK-%%SYSJOBNAME' ODATE '0505' ADD
DO TERMINATE RESULT NOTOK CODE 0055
ELSE
DO REMARK DATA 'SUM IS NOT OVER 1000000: SUM=%%SUM'
DO TERMINATE RESULT OK CODE 0000

Example 2
The sample file provided below lists inventory information for an assembly shop.
 Header information is listed in lines 1 through 5. Item information is listed in rows 12 through 59.
 Each item is assigned to a department. Each department has a name and a number associated with
it. The data in the file is organized so that item information is sorted by department.
 Items are also associated with group numbers. The group number of each item is specified as part of
the item number, in positions 6 through 10. Each group number begins with a ‘-’.
The purpose of the rule definition is to determine if items must be ordered for department 100 – Final
Assembly Shop – group -781. This is determined by adding the total amount currently in stock for
department 100, group -781, and comparing this number to the minimum on-hand amount (that is stored
in the Control-M/Analyzer Database). If items must be ordered, TSO user M18B is notified by the Shout
facility, a remark is issued, and the rule is terminated with a NOTOK result.

522
Control-M/Analyzer User Guide

Figure 296 Rule Definition Process Sample Report – Example 2


----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9-
DATE: 08.08.00
UPDATE: 08.08.00
INVENTORY REPORT
----------------
WAREHOUSE NO: 1001 DEPARTMENT: 100 - FINAL ASSEMBLY SHOP
---- ---------------------------
SHELF QNTY QNTY QNTY QNTY IN TOTAL PART
ITEM NO. DESCRIPTION LIFE UNIT AVAIL ORDER PROCESS QNTY CLASS
----------- ---------------- ---- ---- ----- ------ ------- ------- -----------
1233-781-21 RIVET D. 0.1 ACR NONE KG 100.00 250.00 350.00 FLOOR STOCK
1233-781-25 RIVET D. 0.5 ACR NONE KG 500.00 500.00 1000.00 FLOOR STOCK
1233-781-27 RIVET D. 0.7 ACR NONE KG 100.00 100.00 200.00 FLOOR STOCK
1234-781-21 RIVET D. 0.1 ACP NONE KG 100.00 100.00 FLOOR STOCK
2200-700-22 RUBBER RING D. 2.2 1 MON EA 10.00 10.00 20.00 FLOOR STOCK
2200-700-27 RUBBER RING D. 2.7 1 MON EA 15.00 5.00 20.00 FLOOR STOCK

DATE: 08.08.00
UPDATE: 08.08.00
INVENTORY REPORT
----------------

WAREHOUSE NO: 1002 DEPARTMENT: 101 - WINGS ASSEMBLY SHOP


---- ---------------------------

SHELF QNTY QNTY QNTY QNTY IN TOTAL PART


ITEM NO. DESCRIPTION LIFE UNIT AVAIL ORDER PROCESS QNTY CLASS
----------- ---------------- ---- ---- ----- ------ ------- ------- -----------
1233-781-21 RIVET D. 0.1 ACR NONE KG 100.00 250.00 350.00 FLOOR STOCK
1233-781-22 RIVET D. 0.1 BCR NONE KG 10.00 50.00 60.00 FLOOR STOCK
1233-781-25 RIVET D. 0.5 ACR NONE KG 500.00 500.00 1000.00 FLOOR STOCK
1233-781-26 RIVET D. O.5 BCR NONE KG 25.00 25.00 50.00 FLOOR STOCK
1233-781-27 RIVET D. 0.7 ACR NONE KG 100.00 100.00 200.00 FLOOR STOCK
1233-781-28 RIVET D. 0.7 BCR NONE KG 20.00 80.00 100.00 FLOOR STOCK
1234-781-21 RIVET D. 0.1 ACP NONE KG 100.00 100.00 FLOOR STOCK

523
Control-M/Analyzer User Guide

Figure 297 Rule Definition – Example 2


HEADER OWNER 'M18' CREATOR 'M18B' GROUP 'INVENTORY'
DATE '080800' TIME '153005'
DESC 'INVENTORY CHECKS AND BALANCES'
/*
* EXAMINE THE FILE ASSOCIATED WITH DDNAME INVINP, IN THE CURRENT
* STEP.
* (THE FILE CONTAINS THE REPORT LISTED ABOVE.)
*/
EXECUTE 'INVFILE'
ON_DD DD 'INVINP'
/*
* START PROCESSING LINES WHEN THE STRING 'FINAL' IS FOUND
* PROCESS LINES THAT HAVE THE STRING '-781' IN POS 6-10
* (BUT ONLY LINES 12-59 OF EACH PAGE)
* STOP PROCESSING LINES WHEN THE STRING 'WINGS' IS FOUND
*/
WHEN FLINE +6 TLINE +7 FCOL +1 TCOL +100 SEARCH 'FINAL'
STOPWHEN FLINE 6 TLINE 7 FCOL 1 TCOL 100 SEARCH 'WINGS'
AND
WHEN FLINE 12 TLINE 59 FCOL +6 TCOL +10 SEARCH '-781'
/*
* ACCUMULATE THE DATA IN COLUMNS 84-94 IN THE VARIABLE QTY
*/
DO EXTRACT 'QTY' LEVEL 1 LINE +0 FCOL +78 TCOL +88 TYPE SU

/*
* SET DATABASE VARIABLE WITH COMPUTED QTY.
* CHECK IF QTY IS UNDER MINIMUM (USING DATA-BASE), AND
* ACT ACCORDINGLY.
*/
EXECUTE 'BAL'
ON_DATA
ALWAYS
DO PRINT
DATA 'TOTAL QUANTITY FOR FINAL ASSEMBLY SHOP GRP 781 IS %%QTY'
DO SET 'DB_INVENTORY.QTY_781' EVAL 'QTY'

IF 'QTY < DB_INVENTORY.MIN_781_IN_STOCK@G0'


DO SHOUT MSG 'PLEASE ORDER NEW STOCK OF GRP 781 (QTY=%%QTY)'
URGENCY 'R' DEST 'TSO-M18B'
DO REMARK DATA 'REQUEST ORDER OF STOCK FOR GRP QTY'
DO TERMINATE RESULT NOTOK CODE 0004
ELSE
DO REMARK DATA 'STOCK OF GRP 781 IS OK'
DO TERMINATE RESULT OK CODE 0000

Example 3
The sample file provided below lists personnel information.
 Employee information can be located in lines 5 through 60.
 A period follows the first initial of each employee. This period is used as an indicator to determine if
employee information exists on the current line.
This rule definition determines if employees have exceeded their maximum number of sick or vacation
days. This sample rule definition first initializes variables and prints out the header of a report. Then, the
name, number of sick days, and the number of vacation days are extracted and validated (by calling
another block within the same rule definition). The extracted information is printed, including an analysis
of the balancing result.

524
Control-M/Analyzer User Guide

Figure 298 Rule Definition Process Sample Report – Example 3


----+----1---+----2----+----3---+----4---+----5---+----6----+----7---+----8----+----9---+----0----+----1----+--
--2
E M P L O Y E E S R E P O R T ----- FOR MANAGEMENT DEPARTMENT DATE: 08/08/00
EMPLOYEE EMPLOYEE OFFICE ANNUAL SOCIAL NO. OF JOB CLASS UNION INSURANCE SICK VAC
NO. NAME NO. SAL SECURITY NO. DEPENDENTS CODE DUES DAYS DAYS
-------- -------------- ------ ------ ------------ ---------- --------- ------ --------- ---- ----
64263 A. HERMAN 01 97,000 XXX-YY-ZZZZ 4 212.00 372.00 04 14
64535 V. GOLD 06 57,000 XXX-YY-ZZZZ 2 106.00 252.00 01 05
65173 S. PATTEL 14 86,500 XXX-YY-ZZZZ 2 234.00 390.00 02 09
65225 D. HAMILTON 08 67,500 XXX-YY-ZZZZ 2 156.00 222.00 01 07
65229 J. NEWMAN 19 46,500 XXX-YY-ZZZZ 5 133.00 399.00 00 07
65253 T. MASUIE 14 39,500 XXX-YY-ZZZZ 3 214.00 181.00 01 07
65474 S. SMITH 16 64,500 XXX-YY-ZZZZ 6 044.00 056.00 00 06
65551 J. WAYNE 06 55,000 XXX-YY-ZZZZ 6 151.00 222.00 03 07
65571 J. TAYLOR 11 29,000 XXX-YY-ZZZZ 2 156.00 220.00 01 07
65653 R. JOHNSON 14 26,000 XXX-YY-ZZZZ 3 119.00 256.00 04 07
65763 R. BURKE 07 30,500 XXX-YY-ZZZZ 2 098.00 301.00 01 06
65774 R. ONYON 08 27,500 XXX-YY-ZZZZ 2 156.00 222.00 01 07
65838 G. LEVY 04 29,500 XXX-YY-ZZZZ 2 065.00 118.00 02 07
65965 J. WEISSMAN 04 37,500 XXX-YY-ZZZZ 4 151.00 222.00 05 00

Figure 299 Rule Definition – Example 3


HEADER OWNER 'M18' CREATOR 'M18B' GROUP 'ADMIN'
DATE '080800' TIME '153005'
DESC 'VACATIONS/SICK-LEAVES CHECK'
/*
* INITIALIZE VARIABLES, AND SET REPORT HEADER.
*/
EXECUTE 'INIT'
ON_DATA
ALWAYS
DO SET 'COUNTER' EVAL '0'
DO SET 'UNREASON' EVAL '0'
DO PRINT DATA ' UNREASONABLE SICK/VACATION DAYS'
DO PRINT DATA '================================='
DO PRINT DATA '+--+---------------+------+-----+'
DO PRINT DATA '| | NAME | SICK | VAC |'
DO PRINT DATA '+--+---------------+------+-----+'

/*
* EXAMINE THE FILE 'CTB.PROD.EMPREP'
* (THE FILE CONTAINS THE REPORT LISTED ABOVE.)
*/
EXECUTE 'INPUT'
ON_FILE 'CTB.PROD.EMPREP'
/*
* PROCESS EACH LINE THAT HAS '.' IN POSITION 13
*/
WHEN FLINE +1 TLINE +60 FCOL +13 TCOL +14 SEARCH '.'
/*
* EXTRACT THE NAME, NUMBER OF VACATION DAYS, AND
* NUMBER OF SICK-DAYS.
*/
DO EXTRACT 'NAME' LEVEL +0 LINE 0 COL -2
DO EXTRACT 'SICK' LEVEL +0 LINE 0 COL 87
DO EXTRACT 'VAC' LEVEL +0 LINE 0 COL 93
/*
* CALL ANOTHER BLOCK TO CHECK THE VALIDITY OF THE DATA.
*/
DO BLOCK 'CHECK' PARAMS 'NAME,SICK,VAC'
/*
* PRINT END OF REPORT, CHECK RESULTS AND FINISH.
*/
EXECUTE 'FIN'
ON_DATA
ALWAYS
DO PRINT DATA '+--+---------------+------+-----+'
DO PRINT DATA 'CHECKED %%COUNTER USERS, FOUND %%UNREASON
UNREASONABLE DAYS'
DO REMARK DATA 'CHECKED %%COUNTER USERS, FOUND %%UNREASON
UNREASONABLE DAYS'
IF 'UNREASON > 5'
DO TERMINATE RESULT NOTOK CODE 2000

525
Control-M/Analyzer User Guide

IF 'UNREASON > 3'


DO TERMINATE RESULT TOLER CODE 4
ELSE
DO TERMINATE RESULT OK

/*
* SPECIAL BLOCK TO CHECK DATA (CALLED PREVIOUSLY)
*/
EXECUTE 'CHECK'
ON_DATA
ALWAYS
DO SET 'COUNTER' EVAL 'COUNTER+1'
IF 'BARG02 > 90 | BARG03 > 30'
DO PRINT DATA '| |%%BARG01| %%BARG02 | %%BARG03 |'
DO SET 'UNREASON' EVAL 'UNREASON+1'

526
6
6
Mission Definition Parameters
This chapter includes the following topics:
 Mission Definition Parameters (on page 528)
• General Mission Parameters (on page 529)
• Basic Scheduling Parameters (on page 530)
• Runtime Scheduling Parameters (on page 533)
• Rule Execution Parameters (on page 533)
 Parameter Descriptions (on page 534)
 CATEGORY: Mission Definition Parameter (on page 535)
 CONFCAL: Mission Definition Parameter (on page 537)
 DATES: Mission Definition Parameter (on page 540)
 DAYS: Mission Definition Parameter (on page 542)
 DESC: Mission Definition Parameter (on page 550)
 DOCLIB: Mission Definition Parameter (on page 552)
 DOCMEM: Mission Definition Parameter (on page 554)
 GROUP: Mission Definition Parameter (on page 556)
 IN: Mission Definition Parameter (on page 558)
 JOB: Mission Definition Parameter (on page 561)
 MAXWAIT: Mission Definition Parameter (on page 563)
 MINIMUM: Mission Definition Parameter (on page 566)
 MISSION: Mission Definition Parameter (on page 568)
 MONTHS: Mission Definition Parameter (on page 570)
 NOT LATER THAN: Mission Definition Parameter (on page 571)
 OWNER: Mission Definition Parameter (on page 573)
 PDS: Mission Definition Parameter (on page 575)
 PRIORITY: Mission Definition Parameter (on page 577)
 RETRO: Mission Definition Parameter (on page 578)
 RULELIB: Mission Definition Parameter (on page 581)
 RULENAME: Mission Definition Parameter (on page 582)
 SCOPE: Mission Definition Parameter (on page 583)

527
Control-M/Analyzer User Guide

 SET VARS: Mission Definition Parameter (on page 586)


 STEP: Mission Definition Parameter (on page 587)
 TIME: Mission Definition Parameter (on page 589)
 WDAYS: Mission Definition Parameter (on page 592)

Mission Definition Parameters


The various criteria and instructions governing each mission performed under Control-M/Analyzer are
called Balancing Mission parameters. This chapter describes these parameters and their specific uses.
Balancing Mission parameters are defined only one time for each mission. Control-M/Analyzer uses this
basic framework of instructions for numerous executions of the same balancing mission. Of course, these
instructions can be modified at any time by various Control-M/Analyzer facilities.
Balancing Mission parameters are defined by the Online Scheduling facility using preformatted screens.
Figure 300 Balancing Mission Definition Screen
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY -------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR O
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.10.10

Before proceeding with this chapter, read


 Invoking the Control-M/Analyzer Runtime Environment (on page 41)
 Mission Definition Screen (on page 133)
 Basic Parameters (on page 95)
All parameter definitions are stored as members in standard user libraries. Each member is composed of
instructions for one or more balancing mission categories (for example, DAILY, MONTHLY). Maintenance
of these libraries and management of balancing mission instructions are performed using the Online
Scheduling facility.
This chapter contains a comprehensive description of all balancing mission parameters.
Balancing Mission parameters that can be specified for each category are of four basic types:

528
Control-M/Analyzer User Guide

 General Mission parameters specify basic mission information such as the mission name and the
mission category.
 Basic Scheduling parameters specify dates to schedule a mission.
 Runtime Scheduling parameters specify runtime conditions required to activate a mission.
 Rule Execution parameters specify runtime settings for initialization of System variables (that control
rule processing) and for creation and initialization of Local variables required by the rule.
Different scheduling parameters can be specified for each category of a mission. For more information,
see CATEGORY: Mission Definition Parameter (on page 535).
This chapter first summarizes the parameters in each of the four groups listed above, and then describes
each parameter, in alphabetical order. Each parameter description includes the parameter name in capital
letters, a brief explanation of the purpose of the parameter, a description of the required format, an
extract or sample of the Control-M/Analyzer screen to illustrate where and how the parameter fields are
entered, and practical examples to further illustrate implementing the parameter.

General Mission Parameters


General Mission parameters specify general information about the mission.
Table 276 Control-M/Analyzer General Mission Parameters

Parameter Description

CATEGORY Balancing mission category (for example, DAILY, MONTHLY,


WORKDAY).

MISSION Name of the balancing mission.

JOB Name of the job upon that the mission will act.

STEP Job steps upon that the mission will act.

SCOPE Extent to which a mission can be executed (for example, only once,
several times by a single job step, several times by the same job, or
many times by different jobs).

RULENAME Rule to be executed.

RULELIB Library where the rule is located.

OWNER ID of the user who owns this mission.

GROUP Name for a user-defined group (for example, ACCOUNTING,


INVENTORY, MAIN_BRANCH).

529
Control-M/Analyzer User Guide

Parameter Description

DESC Description of the balancing mission (free text).

DOCMEM Name of the member in which the mission documentation resides.

DOCLIB Name of the library in which the mission documentation resides.

Basic Scheduling Parameters


Basic Scheduling parameters specify on what dates the mission is a candidate for activation.
The New Day procedure determines if the balancing mission is a candidate for execution on a specific
date. If a balancing mission is a candidate for execution on a specific date, the balancing mission is placed
in the Active Balancing file.
Each balancing mission in the Active Balancing file has an original scheduling date associated with it. This
is the date on that data should be balanced according to the Basic Scheduling parameters. This date is
not necessarily the same as the current calendar date or the current installation working date.
Note: Basic Scheduling parameters may be ignored by the Control-M/Analyzer New Day procedure,
depending on the mode of operation.
Table 277 Basic Scheduling Parameters

Parameter Description

DAYS Days of the month to activate the balancing mission.

WDAYS Days of the week to activate the balancing mission – Sunday,


Monday, and so on.

MONTHS Months to activate the balancing mission.

CONFCAL Name of a user-defined calendar for confirming schedule dates.

DATES Specific dates in the year to activate the balancing mission – day
and month.

RETRO A flag that specifies whether the balancing mission should be


ordered for possible execution after its original scheduling date has
passed.

MAXWAIT Number of days that the balancing mission should wait to be


executed after its original scheduling date has passed and before
the mission is disregarded.

530
Control-M/Analyzer User Guide

Parameter Description

MINIMUM Minimum number of free tracks required for the library defined in
parameter PDS under that the balancing mission is ordered.

PDS Name of a partitioned data set (library) to be checked for minimum


free space.

Description
Basic Scheduling parameters determine on which day a mission is scheduled in (ordered to) the Active
Environment.
Basic Scheduling parameters are divided into the four groups listed below. Parameters must be selected
from only one of the first three groups. Use of the fourth group (D) is optional.
Table 278 Basic Scheduling Parameter Groups

Group Parameters

A DAYS
WDAYS
MONTHS
CONFCAL

B DATES

C PDS
MINIMUM

D RETRO
MAXWAIT

The various Basic Scheduling parameters and subparameters provide different methods of specifying a
missions schedule. Each mission definition may use any one or several of these parameters, depending on
scheduling requirements.
Each Basic Scheduling parameter is described in detail in the following pages. However, the
interrelationships between some of these parameters are described briefly below.

531
Control-M/Analyzer User Guide

DAYS/DCAL WDAYS/WCAL
These parameters are all optional.
The DAYS parameter identifies days of the month on that the mission should be scheduled (for
example, 1st day of the month, 3rd working day of the month). Several formats are available for
specifying DAYS values.
The WDAYS parameter identifies days of the week on that the mission should be scheduled. For
example, the 1st day of the week, the 2nd working day of each week, and so on. Several formats are
available for specifying WDAYS values.
A calendar specifies days of the year on which a rule can be scheduled, known as working days. For more
information on calendars and the IOA Calendar Facility, see IOA Calendar Facility (on page 204).
When the DAYS and DCAL parameters are both specified, they work as a complementary unit, as
described later in this chapter.
Similarly, when the WDAYS and WCAL parameters are both specified, they work as a complementary unit,
as described later in this chapter.
When values for the DAYS (/DCAL) and WDAYS (/WCAL) parameter are both specified in the same
balancing mission, the resulting schedule is determined by the value specified in field AND/OR.

CONFCAL/SHIFT
A calendar specified in CONFCAL is not used for mission scheduling, but is used instead for validating a
scheduled date. Only missions that have satisfied all other specified basic scheduling criteria are checked
against the CONFCAL calendar. If the day is a working day in the CONFCAL calendar, the mission is
scheduled on that day. Otherwise, the mission is either shifted to (scheduled on) another day according to
the value specified in the SHIFT parameter, or the mission is not scheduled (if no SHIFT value has been
specified).
CONFCAL calendars are useful for handling holidays and other scheduling exceptions.

Defining a Schedule – Internal Scheduling Logic


When defining scheduling missions, it is useful to understand the IOA Scheduling facility logic that
determines whether to order a mission on a specific day. This logic is described below:
1. DAYS and DCAL parameters are checked independently and a first tentative scheduling decision is
created.
2. Similarly, WDAYS and WCAL parameters are checked independently and a second tentative scheduling
decision is created.
3. A third tentative scheduling decision is created based on the above two decisions and the AND/OR
value linking them.
If DAYS and DCAL are not specified, this third scheduling decision is identical to the second
scheduling decision. If WDAYS and WCAL are not specified, this third scheduling decision is identical
to the first scheduling decision.
4. If CONFCAL and SHIFT are specified, the third scheduling decision is adjusted according to the
CONFCAL and SHIFT criteria. The third decision (as adjusted) becomes the final scheduling decision.

532
Control-M/Analyzer User Guide

5. The IOA Scheduling facility decides whether to schedule a mission based on the algorithm outlined
above.

Runtime Scheduling Parameters


The balancing mission is executed only when all Runtime Scheduling parameter specifications have been
fulfilled.
The Control-M/Analyzer Runtime Environment determines whether the conditions required for balancing
are available. If they are, the balancing mission can process the data.
Table 279 Runtime Scheduling parameters

Parameter Description

IN Prerequisite conditions for the execution of the balancing mission.

TIME Time limits (from, until) for balancing mission execution.

NOT LATER THAN Specification of a time at that the mission is activated regardless of
the existence of prerequisite conditions.

PRIORITY For future use.

Rule Execution Parameters


Rule Execution parameters define the settings of Local or System variables that control rule execution.
In future versions, Rule Execution parameters will specify information that affects how the rule is
executed.
Table 280 Rule Execution Parameters

Parameter Description

SET VARS For future use.

533
Control-M/Analyzer User Guide

Parameter Descriptions
The following pages contain detailed descriptions of all Mission Definition parameters available in the
Mission Definition screen. Parameters are arranged in alphabetical order. Within each parameter,
subparameters are arranged according to the order of the fields on the screen.
Each parameter begins on a new page, including
 a brief explanation of the purpose of the parameter
 the format required for defining the parameter within an extract of the Control-M/Analyzer screen
 general information explaining the parameter and its usage
 where applicable, some practical examples illustrating implementation of the parameter
For more information on the Mission Definition facility, see Online Facilities (on page 58).

534
Control-M/Analyzer User Guide

CATEGORY: Mission Definition Parameter


Specifies the category of the balancing mission.
Figure 301 CATEGORY Parameter Format

Mandatory. CATEGORY specifies a category name of 1 through 20 characters. No blanks (except trailing
blanks) can be specified.

General Information
Scheduling parameters for each mission can be specified under different categories. It is possible to use
different scheduling criteria for different calendar cycles (for example, daily, monthly, yearly). Each set of
balancing criteria is called a category.
Any number of categories (for example, any number of scheduling criteria) can be defined. BMC
recommends that only one category (for example, DAILY) be used for all missions in early stages of
Control-M/Analyzer implementation.

535
Control-M/Analyzer User Guide

Example
Figure 302 CATEGORY Parameter Example
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY--------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

536
Control-M/Analyzer User Guide

CONFCAL: Mission Definition Parameter


Specifies the name of a calendar used to confirm the scheduling of a mission.
See also DAYS and WDAYS.
Figure 303 CONFCAL Parameter Format

Optional. CONFCAL subparameters are described below:


Table 281 CONFCAL Subparameters

Subparameter Description

CONFCAL Specifies a valid calendar (member) name of 1 through 8


characters.
A calendar specified in CONFCAL is used for validating schedule
dates. Missions to be scheduled on a day, based on other specified
scheduling criteria, are checked against the CONFCAL calendar. If
the day is a working day in the CONFCAL calendar, the mission is
scheduled on that day. Otherwise, the SHIFT parameter determines
whether the mission is shifted to (scheduled on) another day or is
not scheduled.

537
Control-M/Analyzer User Guide

Subparameter Description

SHIFT When a mission fails confirmation for scheduling on a given day


because the day is not a working day in the CONFCAL calendar,
SHIFT determines if and when the mission will be alternatively
scheduled.
Valid SHIFT values:
 blank – No shifting occurs. The mission is not scheduled.
Default.
 > – The mission is scheduled on (shifted to) the next working
day, according to the CONFCAL calendar.
 < – The mission is scheduled on (shifted to) the previous
working day, according to the CONFCAL calendar.

Note: Specifying a SHIFT value does not ensure that the job will be
scheduled. SHIFT cannot add scheduling dates; it can only shift a
job to a scheduling date that is already defined. If SHIFT does not
find a suitable date in the other scheduling criteria, the job is not
scheduled.

General Information
CONFCAL calendars are especially useful for handling holidays and other scheduling exceptions.
If not specified, missions are scheduled according to other scheduling criteria without confirmation.
CONFCAL should not contain the name of a periodic calendar. If it does, no day will pass the confirmation.
SHIFT cannot be specified unless CONFCAL is specified. When CONFCAL is specified, SHIFT is optional
(for example, blank defaults to no shifting).
The CONFCAL parameter cannot be used with the PDS and MINIMUM parameters.

Example
This example is based on the following assumptions:
 The current month is September 2001.
 Working days are defined in calendar WORKDAYS that contains the following working days (indicated
by Y) for September 2001:
--S-------------S-------------S-------------S-------------S--
1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 +
Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y

Start of the week is defined as Monday. Weeks start on the following dates in September: 3rd, 10th, 17th,
24th.

538
Control-M/Analyzer User Guide

Schedule the rule on the 1st, 7th and 15th day of the month if they are both Saturdays and working days
in WORKDAYS. If the day of the month (1st, 7th, 15th) is not a Saturday, do not schedule the rule. If the
day of the month is a Saturday but is not a working day, schedule the rule on the next working day.
DAYS - 1,7,15
AND/OR - AND
WDAYS - 6
CONFCAL - WORKDAYS
SHIFT - >

The mission is scheduled on the days of the month indicated by an asterisk:


Figure 304 CONFCAL Parameter Example

539
Control-M/Analyzer User Guide

DATES: Mission Definition Parameter


Specifies dates, by month and day, on that the mission should be scheduled for execution.
Figure 305 DATES Parameter Format

Optional. Valid values are 4-character dates in mmdd or ddmm format, depending on the site standard.
A maximum of 12 dates can be specified.

General Information
The mission is scheduled for execution only on the dates specified in parameter DATES.
The DATES parameter cannot be used with the PDS, MINIMUM, MONTHS, DAYS, and DCAL parameters.
To specify more than 12 dates for one mission, define the dates in a calendar (instead of using this
parameter) and specify the calendar in DCAL (or WCAL).

Example
Schedule a mission for the 21st of June and the 21st of December (mmdd format):

540
Control-M/Analyzer User Guide

Figure 306 DATES Parameter Example


---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY------BM.S
)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS WCAL
MONTHS 1- 2- 3- 4- 5- 6- 7- 8- 9- 10- 11- 12-
DATES 0621 1221
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

541
Control-M/Analyzer User Guide

DAYS: Mission Definition Parameter


Specifies the days of the month on that the mission should be scheduled for execution.
See also CONFCAL and WDAYS.
Figure 307 DAYS Parameter Format

Optional. The DAYS parameter specifies days of the month on that missions should be scheduled,
provided other basic scheduling criteria are met. Values for DAYS can be specified alone, or they can be
specified in conjunction with a calendar specified in the DCAL parameter. DAYS and DCAL can also be
specified in conjunction with WDAYS and WCAL (described in WDAYS: Mission Definition Parameter (on
page 592)).
DAYS subparameters are described in Table 282.
Table 282 DAYS Subparameters

Subparameter Description

DAYS Days of the month on which to schedule a mission. The months in


which to order missions are specified in the MONTHS parameter,
which is described in MONTHS: Mission Definition Parameter (on
page 570). Various formats (described below in "Valid Formats for
the DAYS parameter") can be used to specify DAYS (for example, 3
means the 3rd day of the month, L2 means the day before the last
day of the month, D1PA means the 1st day in period A).

DCAL Name of a calendar containing a predefined set of dates (referred to


as working days) on that a mission should be scheduled. A specified
name must be a valid member name of 1-8 characters, or an * to
indicate that the calendar specified in the CONFCAL parameter
should be used for scheduling. For more information on how to
define, use and modify calendars, see IOA Calendar Facility (on
page 204).

542
Control-M/Analyzer User Guide

Subparameter Description

Note: A calendar specified in DCAL does not have to exist when


defining mission parameters. However, it must exist when the
mission is ordered.

AND/OR Conjunctional parameter used to link the DAYS and WDAYS


parameters when both are specified.

A (AND) Both DAYS (and DCAL) and WDAYS (and WCAL) criteria must be
satisfied to schedule a mission.

O (OR) Either DAYS (and DCAL) or WDAYS (and WCAL) criteria must be
satisfied to schedule a mission. Default.
If A (AND) is specified when either DAYS or WDAYS is specified (but
not both), the missing DAYS or WDAYS value is automatically set to
ALL.

Assuming all other Basic Scheduling criteria are met:


 when DAYS are specified without DCAL, the mission is scheduled on the specified days (in the
specified months)
 when DCAL is specified without DAYS, the mission is scheduled on the working days marked in the
DCAL calendar
 when DAYS and DCAL are both specified, scheduling depends on the combination of working days
defined in the calendar and the values and format of the DAYS parameter
 when both DAYS and WDAYS criteria are specified, scheduling depends on the AND/OR subparameter
connecting them
Valid Formats for the DAYS parameter
Valid formats for the DAYS parameter, and how they relate to DCAL, are described below.
In the following non-periodic scheduling formats:

543
Control-M/Analyzer User Guide

 n is an integer from 1 through 31.


 Multiple values can be specified (separated by commas) in any order.
 DCAL should not contain the name of a periodic calendar.
Table 283 Non-Periodic Scheduling Formats

Format Description

ALL All days of the month. If ALL is specified, other DAYS values cannot be
specified with it.

n,... Specific days of the month.

+n,... Days of the month in addition to the working days specified in the DCAL
calendar. DCAL is mandatory.

–n,... Schedule the mission on all days except the nth day from the beginning
of the month. DCAL is mandatory.

>n,... Schedule the mission on the indicated day if it is a working day in the
DCAL calendar. Otherwise, schedule the mission on the next working
day that is not negated by a –n value in this parameter. This format is
frequently used for holiday handling. DCAL is mandatory.

<n,... Schedule the mission on the indicated day if it is a working day in the
DCAL calendar. Otherwise, schedule the mission on the last previous
working day that is not negated by a –n value in this parameter. This
format is frequently used for holiday handling. DCAL is mandatory.

Dn,... Schedule the mission on the nth working day from the beginning of the
month. DCAL is mandatory.

–Dn,... Schedule the mission on all working days except the nth working day
from the beginning of the month. DCAL is mandatory.

Ln,... Schedule the mission on the nth day (or nth working day if DCAL is
defined) counting backward from the end of the month. DCAL is
optional.

–Ln,... If DCAL is defined, schedule the mission on all working days except the
nth working day counting backward from the end of the month. If DCAL
is not defined, schedule the mission on all days except the nth day from
the end of the month. DCAL is optional.

544
Control-M/Analyzer User Guide

In the following periodic scheduling formats:


 n is any integer from 1 through 63 and i is any valid period identifier. An * can be specified as the i
value to represent all periods. An * can be specified as the n value in format DnPi to represent all
days. (* is not a valid n value in formats –DnPi, LnPi and –LnPi.)
 A period can span any number of days, but by default, no more than 33 days can elapse after the
appearance of one identifier in a period until the appearance of the next matching identifier in the
same period. Once a gap of 33 days has been reached, the period automatically closes. (The 33-day
default can be changed by the INCONTROL administrator.)
 The name of a periodic calendar must be specified in DCAL. For details concerning periodic calendars,
see IOA Calendar Facility (on page 204).
• DnPi,... Schedule the mission on the nth day of period i from the beginning of the period.
• –DnPi,... Schedule the mission on all days of period i except the nth day of period i from the
beginning of the period.
• LnPi,... Schedule the mission on the nth day of period i counting backward from the last day of
the period.
• –LnPi,... Schedule the mission on all days of period i except the nth day of period i counting
backward from the last day of the period.

General Information
Negative values take precedence over positive values when determining whether a mission is scheduled
on a certain date. If a negative value (for example, format –n, –Dn, –Ln, –DnPi, or –LnPi) in either the
DAYS or WDAYS field prevents a mission from being scheduled on a date, the mission will not be
scheduled on that date even if a positive value (for example, Ln) would otherwise result in the mission
being scheduled on that date.
A maximum of eight values (for example, of types DnPi, –DnPi, LnPi, and –LnPi) can be designated in any
desired order.
If periodic and non-periodic values are mixed when specifying the DAYS parameter, processing will
depend on the calendar type specified in the DCAL parameter.
 If a non-periodic calendar is specified in the DCAL parameter, only non-periodic values in the DAYS
parameter are processed; periodic values are ignored. In this case, negative periodic values (for
example, –DnPi, –LnPi) are also ignored and do not supersede other values.
 If a periodic calendar is specified in the DCAL parameter, all periodic values and the negative
non-periodic value -n in the DAYS parameter are processed; all other non-periodic values are ignored.
–D*Pi, –D*P*, –L*Pi and –L*P* are not permitted, because these values would result in ordering the
mission on no days in a period, or no days in all periods, a meaningless request.
The MONTHS parameter is ignored when periodic values are specified in the DAYS or WDAYS parameters.
The DAYS parameter cannot be used with the PDS, MINIMUM, and DATES parameters.

545
Control-M/Analyzer User Guide

Examples
The examples in this chapter are based on the following assumptions:
 The current month is December 2001.
 Working days are defined in the WORKDAYS calendar that contains the following working days
(indicated by Y) for December 2001:
--S-------------S-------------S-------------S-------------S--
1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1
Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y

 The PERIDAYS periodic calendar contains the following periodic definition for December 2001. These
examples assume that all other days of this calendar are blank.
--S-------------S-------------S-------------S-------------S--
1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1
B C A A B B C A A B B C A A B B C A A B B

 Start of the week is defined as Monday. Weeks start on the following dates in December 2001: 3rd,
10th, 17th, 24th, and 31st.
At the end of each example, asterisks in a December 2001 calendar indicate the days on which the
mission is scheduled.
Example 1
Schedule the mission on the 17th day and the last day of the month.
DAYS 17,L01

The mission is scheduled on the days of the month indicated by an asterisk


Figure 308 DAYS Parameter – Example 1:

Example 2
Schedule the mission on all working days of the month except the 6th day of the month, and also
schedule the mission on the 1st day of the month.
DAYS +1,-6
DCAL WORKDAYS

The mission is scheduled on the days of the month indicated by an asterisk:


Figure 309 DAYS Parameter – Example 2

546
Control-M/Analyzer User Guide

Example 3
Schedule the mission on all working days of the month except the first and last working days, and except
the 17th day, of the month.
DAYS -D1,-17,-L1
DCAL WORKDAYS

The mission is scheduled on the days of the month indicated by an asterisk:


Figure 310 DAYS Parameter – Example 3

Example 4
Schedule the mission on the 8th day of the month. If it is not a working day, schedule the mission on the
closest preceding working day.
DAYS <8
DCAL WORKDAYS

The mission is scheduled on the days of the month indicated by an asterisk:


Figure 311 DAYS Parameter – Example 4

Example 5
Schedule the mission on the 1st day of period A, and on all days, except the 2nd day, of period B. Do not
schedule the mission on the 5th day of the month.
DAYS -5,D1PA,-D2PB
DCAL PERIDAYS

The mission is scheduled on the days of the month indicated by an asterisk:


Figure 312 DAYS Parameter – Example 5

Example 6
Schedule the mission on each Monday and on the 1st day of the month.
DAYS 1
AND/OR OR
WDAYS 1

The mission is scheduled on the days of the month indicated by an asterisk:

547
Control-M/Analyzer User Guide

Figure 313 DAYS Parameter – Example 6

Example 7
Schedule the mission on the 3rd day of the month provided it is a Monday.
DAYS 3
AND/OR AND
WDAYS 1

The mission is scheduled on the days of the month indicated by an asterisk:


Figure 314 DAYS Parameter – Example 7

Example 8
Schedule the mission on the last Monday of the month:
DAYS L1,L2,L3,L4,L5,L6,L7
AND/OR AND
WDAYS 1

The mission is scheduled on the days of the month indicated by an asterisk:


Figure 315 DAYS Parameter – Example 8

Example 9
Schedule the mission on the 1st, 7th and 15th days of the month if they are both Saturdays and working
days. If the day of the month (1st, 7th, 15th) is not a Saturday, do not schedule the mission. If the day of
the month is a Saturday, but it is not a working day, schedule the mission on the next working day.
DAYS 1,7,15
AND/OR AND
WDAYS 6
CONFCAL WORKDAYS
SHIFT >

The mission is scheduled on the days of the month indicated by an asterisk:


Figure 316 DAYS Parameter – Example 9

548
Control-M/Analyzer User Guide

Example 10
Schedule the mission to run on the first Friday after the 15th of the month.
DAYS 16,17,18,19,20,21,22
AND/OR AND
WDAYS 5

The mission is scheduled on the days of the month indicated by an asterisk:


Figure 317 DAYS Parameter – Example 10

549
Control-M/Analyzer User Guide

DESC: Mission Definition Parameter


Describes the mission in free text.
Figure 318 DESC Parameter Format

Optional. The DESC parameter specifies a description text of 1 through 50 characters. One description line
may be specified.

General Information
The DESC parameter is informational. It does not affect rule processing. The description is intended to let
the user know the purpose of (or some other key information about) the mission.
The mission description can be specified in any language. It is used as an internal help facility, assisting
the user in controlling the missions under Control-M/Analyzer.
To specify complete mission documentation, see Mission Documentation (on page 138).

550
Control-M/Analyzer User Guide

Example
Figure 319 DESC Parameter Example
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N 00
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

551
Control-M/Analyzer User Guide

DOCLIB: Mission Definition Parameter


Names the library in which the DOCMEM mission description member resides.
Figure 320 DOCLIB Parameter Format

Optional. The default is site-defined or blank.


The DOCLIB parameter specifies a valid data set name of 1 through 44 characters.

General Information
The library can be any standard partitioned data set. The record length must be 80.
Any number of documentation libraries can be used at a site. However, only one documentation library
can be specified in each mission definition.
Note: Users with DOCU/TEXT installed at their sites may specify a DOCU/TEXT library and member.
However, only files with an 80 character record length can be used and only the first 71 characters are
displayed.

552
Control-M/Analyzer User Guide

Example
Mission documentation is written to the INV member in the PROD.CTB.DOC library.
Figure 321 DOCLIB Parameter Example
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION NVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

553
Control-M/Analyzer User Guide

DOCMEM: Mission Definition Parameter


Specifies the name of the member in which mission documentation resides.
Figure 322 DOCMEM Parameter Format

Optional. The DOCMEM parameter specifies a valid member name of 1 through 8 characters.

General Information
This member is used to save detailed documentation written in the DOC lines of the Mission Definition
screen.
Note: Users with DOCU/TEXT installed at their sites may specify a DOCU/TEXT library and member.
However, only files with an 80 character record length can be used and only the first 71 characters are
displayed.

554
Control-M/Analyzer User Guide

Example
Mission documentation is written to the INV member in the PROD.CTB.DOC library.
Figure 323 DOCMEM Parameter Example
--- CONTROL-M/ANALZYER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

555
Control-M/Analyzer User Guide

GROUP: Mission Definition Parameter


Specifies the name of the group.
Figure 324 GROUP Parameter Format

Optional. The GROUP parameter specifies a group name of 1 through 20 characters. Only trailing blanks
are allowed.

General Information
The GROUP parameter facilitates the handling of balancing missions. It enables the retrieval of
information on the balancing missions of a specific group, usually by the Online Tracking and Control
facility, or by the Reporting facility.
Groups can be defined using the Database Variable Online facility.
The group name appears in all important messages relating to the balancing missions of the group.
Jobs, missions, and variables may be grouped for simulation so that complete systems can be tested as a
unit.
During rule execution, the group name specification is checked for existence in the Control-M/Analyzer
Database Variable file. Several invocation methods exist that determine the group name under that a rule
executes:
 direct invocation by a job step or program
The group specified by the job step or program is used. If no group is specified by the job step or
program, the GROUP specification in the rule definition is used.
 invocation by mission
GROUP receives its value from the mission definition. In this case, the group name specified by the
mission definition overrides the group name specified by the rule definition.

556
Control-M/Analyzer User Guide

 invocation by other CONTROL products


When the rule is called using statement DO CTBRULE in Control-M or Control-D, GROUP receives its
value from the Control-M job scheduling definition or the Control-D decollating mission. In this case,
the group name specified by the job or decollating definition overrides the group name specified by
the rule definition.
A detailed explanation of all GROUP features is provided in Introduction (on page 19).

Example
Figure 325 GROUP Parameter Example
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

557
Control-M/Analyzer User Guide

IN: Mission Definition Parameter


Specifies prerequisite conditions for mission execution. The mission is activated only if the specified
prerequisite conditions exist.
Figure 326 IN Parameter Format

Optional (but recommended).


A maximum of two prerequisite conditions can be specified in each IN line. Upon specifying the second
prerequisite condition in a line and pressing Enter, a new line is opened (for specifying additional
prerequisite conditions).
Each specified prerequisite condition consists of the following mandatory subparameters:
Table 284 IN Subparameter

Subparamete
r Description

condName User-supplied descriptive name of 1-20 characters used to identify the


condition.

dateRef 4-character date reference. Valid values are:

date Specific date (in either mmdd or ddmm format, depending


on the site standard).

STAT Static. Indicates that the condition, (for


example, PRINTER-SET) is not date dependent.

ODAT Control-M/Analyzer working date. Default.

PREV Previous scheduling date.

**** Any scheduling date.

558
Control-M/Analyzer User Guide

Subparamete
r Description

$$$$ Any scheduling date.

General Information
The mission is activated only if all the prerequisite conditions (specified in the IN parameter) are satisfied.
A prerequisite condition can represent any user-specified situation. The following are a few examples of
prerequisite conditions:
IMS-ACTIVE
WEEKEND
JOB-EJGH12-FINISHED
SALARY-OK
BRANCH_TRANSMISSION

Mission execution dependencies can be defined and implemented by using prerequisite conditions created
by a DO COND statement. Prerequisite conditions can trigger (or stop) the activation of missions in
Control-M/Analyzer and Control-D, and can also trigger or stop a job or process in Control-M.
Each prerequisite condition is associated with a specific scheduling date. This scheduling date
differentiates between different activations of the same mission for different scheduling dates.
The PREV date reference automatically resolves to a scheduling date reference for the missions previous
scheduling date.
The **** or $$$$ date reference can be any prerequisite condition with the same name as that specified
in parameter IN, with any date reference that will satisfy the IN requirement.
The ODAT of an IN condition is only calculated once – when the mission is first ordered. This date is then
retained until the mission is reordered.

Examples
Example 1
Activate the balancing mission that produces the inventory report when the rule finished OK. When the
rule that produces the inventory report finishes OK, it creates the prerequisite condition INVENTORY-OK.
The inventory report is balanced twice a month, for the 1st and for the 15th. The report for the 15th is
balanced only if the prerequisite condition INVENTORY-OK for that report exists (signifying the job
creating the inventory report ended OK). The existence of the prerequisite condition INVENTORY-OK does
not cause balancing of the report on the 15th.
The job on the 1st does not necessarily run on the 1st of the month. For example, if the inventory job
only finishes executing on the 3rd. Only then is the prerequisite condition INVENTORY-OK of the 1st
created. This is because the prerequisite condition is always associated with a scheduling date and not
with the actual run date.

559
Control-M/Analyzer User Guide

Figure 327 IN Parameter – Example 1


---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS 01, 15 DCAL
AND/OR
WDAYS WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO Y MAXWAIT 00
MINIMUM PDS
===========================================================================
IN INVENTORY-OK ODAT
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

Example 2
In this example a report should be balanced only after the totals of the report have been checked for
reasonableness. The IN parameter can specify a prerequisite condition such as REPORT12-CHECKED, that
is created by the rule that made the check.
Figure 328 IN Parameter – Example 2
---- CONTROL-M/ANALZYER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS 2,3,4,5,6 DCAL
AND/OR
WDAYS WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO Y MAXWAIT 00
MINIMUM PDS
===========================================================================
IN REPORT12-CHECKED ODAT
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

560
Control-M/Analyzer User Guide

JOB: Mission Definition Parameter


Specifies the jobs from which the mission can be invoked.
Figure 329 JOB Parameter Format

Mandatory. JOB specifies a valid job name of 1 through 8 characters. Mask characters can be specified in
the JOB name.

General Information
When Control-M/Analyzer is invoked, the Active Balancing file is scanned for corresponding mission
entries, those entries whose mission name matches parameter MISSION. Corresponding mission entries
are then checked further to determine that mission to execute. For example, the job name specified in the
mission entry should match the JOB parameter. For additional information on the Active Balancing file
search method see Invoking the Control-M/Analyzer Runtime Environment (on page 41).
Job Mask
The JOB field can contain an asterisk (*) as the last character. Any job name with the specified prefix will
match.

561
Control-M/Analyzer User Guide

Example
Figure 330 JOB Parameter Example
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

562
Control-M/Analyzer User Guide

MAXWAIT: Mission Definition Parameter


Specifies the number of extra days the mission can wait in the Active Balancing file for execution.
Figure 331 MAXWAIT Parameter Format

Optional. The MAXWAIT parameter must be a number in the range from 00 through 98 (days) or 99 (no
limit). The default is 00. A leading zero is required.
Table 285 MAXWAIT Values

Value Description

MAXWAIT=00 The mission is not executed if it did not execute on the original
schedule date.

MAXWAIT=99 The mission waits for execution indefinitely (for example, remains in
the Active Balancing file even if it finishes executing.)

MAXWAIT=nn (where nn is an integer from 1 through 98). MISSION is given nn


additional days to execute – the mission’s "second chance."

General Information
The MAXWAIT parameter is used to overcome production delay problems. A mission that is scheduled for
execution on a specific day does not always finish executing that same day. This is the case when the job
that is to be balanced has not yet run. A mission may be delayed due to a number of reasons, such as
hardware failure, a heavy production workload, or a bug in one of the predecessors of the mission.
Therefore, it may be desirable to specify an additional number of days that the mission should remain
available for execution.
When a mission is scheduled due to the parameter RETRO=Y, the mission is always given at least one
day to execute. This occurs even if the current working date exceeds the MAXWAIT days after the last
original scheduling date of the mission.

563
Control-M/Analyzer User Guide

Examples
Example 1
The balancing mission should wait for execution indefinitely until the runtime conditions required for the
mission are available:
MAXWAIT=99

Example 2
The balancing mission should be given an extra three days to execute after its original scheduling date
has passed:
DAYS=2,4,6
MAXWAIT=3

Assume that the balancing mission will not run due to the absence of the required runtime conditions. The
balancing mission that is scheduled for the 2nd of the month will wait from the 2nd through the 5th to be
executed.
On the 6th, Control-M/Analyzer times out and the balancing mission scheduled for the 2nd will not be
executed. The balancing missions scheduled for the 4th and 6th will wait for execution until the 7th and
9th.
Figure 332 MAXWAIT Parameter – Example 2
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS 2,4,6 WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO Y MAXWAIT 03
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

564
Control-M/Analyzer User Guide

Example 3
Schedule the balancing mission for every working day, whether the computer is active. Give the balancing
mission one extra day to execute:
DCAL=WORKDAYS,
RETRO=Y,
MAXWAIT=1

Assume that the WORKDAYS calendar, specified in the DCAL parameter, contains the values 15, 16, 18,
and 19. The computer was offline from the 16th up to and including the 18th, and the 15th was the last
date that the mission was scheduled for execution.
Today is the 19th. The balancing mission is scheduled three times with the original scheduling dates of
the 16th, 18th, and 19th.
The balancing missions on the 16th and the 18th are disregarded on the 20th if they have not yet
executed. The balancing mission on the 19th is disregarded only on the 21st.
Figure 333 MAXWAIT Parameter – Example 3
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL WORKDAYS
AND/OR
WDAYS WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO Y MAXWAIT 01
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

565
Control-M/Analyzer User Guide

MINIMUM: Mission Definition Parameter


Checks the number of free tracks required for the library specified in the PDS parameter. This parameter
may be used to define an event that is not related to any date.
Figure 334 MINIMUM Parameter Format

The MINIMUM and PDS parameters are optional, but if one is specified, the other is mandatory.
The MINIMUM parameter specifies the required number of free tracks. This must be a positive 3-digit
number.
The MINIMUM parameter cannot be used with the DAYS, WDAYS, MONTHS, CONFCAL, RETRO, and
DATES parameters.

General Information
The number of unused tracks in the library described by the PDS parameter is counted. If this number is
less than the number specified in the MINIMUM parameter, the mission is scheduled for execution.
Note: The MINIMUM parameter only checks current extents.

566
Control-M/Analyzer User Guide

Example
Schedule the mission when there are less than 20 unused tracks in the ALL.PARMLIB library.
Figure 335 MINIMUM Parameter
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL WORKDAYS
AND/OR
WDAYS WCAL
MONTHS 1- 2- 3- 4- 5- 6- 7- 8- 9- 10- 11- 12-
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM 020 PDS ALL.PARMLIB
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 12.34.10

567
Control-M/Analyzer User Guide

MISSION: Mission Definition Parameter


Specifies the name of the mission that determines rule execution.
Figure 336 MISSION Parameter Format

Mandatory. MISSION displays the mission name. The mission name is specified in the Mission Definition
entry panel or is selected from the Mission list.

General Information
The mission name forms the link between the balancing rule and the balancing mission. The mission
determines which rule should execute and at what time the execution will occur, based on the scheduling
and runtime criteria specified in the Mission Definition screen.
When Control-M/Analyzer is invoked, the Active Balancing file is searched for corresponding mission
entries, those entries whose mission name matches the MISSION parameter. Corresponding mission
entries are then checked further to determine which mission to execute. For additional information on the
Active Balancing file search method see Invoking the Control-M/Analyzer Runtime Environment (on page
41).

568
Control-M/Analyzer User Guide

Example
Figure 337 MISSION Parameter Example
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+

CATEGORY DAILY MISSION INVENTORY


JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

569
Control-M/Analyzer User Guide

MONTHS: Mission Definition Parameter


Specifies months of the year during that the mission may be ordered.
Figure 338 MONTHS Parameter Format

Optional. The default value for all months is Y.

General Information
The mission is ordered only during the months specified with Y in the MONTHS parameter.
The MONTHS parameter cannot be used with the PDS, MINIMUM, and DATES parameters.
When the MONTHS parameter is used, at least one of the following must be specified: DAYS, DCAL,
WDAYS, or WCAL.
The MONTHS parameter is ignored when periodic values are specified in the DAYS or WDAYS parameter.

Examples
Order a balancing mission only in March and September:
MONTHS 1- N 2- N 3- Y 4- N 5- N 6- N 7- N 8- N 9- Y 10- N 11- N 12- N

Order a balancing mission in all months of the year:


MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y

570
Control-M/Analyzer User Guide

NOT LATER THAN: Mission Definition Parameter


Specifies time by which the mission will start executing even if the prerequisite conditions specified in the
IN parameter do not exist.
Figure 339 NOT LATER THAN Parameter Format

Optional. The NOT LATER THAN parameter must be in the format hhmm (where hh is the hour and mm is
the minute).
Example
2101 = 09:01 p.m.
0301 = 03:01 a.m.

General Information
This parameter triggers execution of the mission at the specified time even if prerequisite conditions
specified in the IN parameter do not exist. Use this parameter in those cases where the prerequisite
condition is desirable but not absolutely necessary for execution of the mission.
When the NOT LATER THAN parameter is not specified, the mission executes only if the prerequisite
conditions and the other scheduling requirements are satisfied.

571
Control-M/Analyzer User Guide

Example
Execute the balancing mission at 3:00 a.m. even if the prerequisite conditions do not exist.
Figure 340 NOT LATER THAN Parameter Example
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN REPORT12-CHECKED ODAT
TIME FROM TO NOT LATER THAN 0300 PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

572
Control-M/Analyzer User Guide

OWNER: Mission Definition Parameter


Identifies the user who requests Control-M/Analyzer services. This parameter is mainly used by the
Control-M/Analyzer security mechanism.
Figure 341 OWNER Parameter Format

Mandatory. The OWNER parameter must be from 1 through 8 characters in length.

General Information
The OWNER parameter is used by the Control-M/Analyzer internal security mechanism to determine those
operations that each user is authorized to perform.
The OWNER parameter is also used to enable more convenient handling of missions and rules. When
using the Online Scheduling, Tracking and Control facility, you can limit the display of Control-M/Analyzer
information to specified owners.
The OWNER parameter is used in interactions with external security products, such as TOP SECRET, RACF
and ACF2.
The default OWNER is dependent on the online environment of the site (CICS, TSO, and so on).

573
Control-M/Analyzer User Guide

Example
Figure 342 OWNER Parameter Example
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

574
Control-M/Analyzer User Guide

PDS: Mission Definition Parameter


Checks a partitioned data set (library) for the minimum number of unused tracks.
Figure 343 PDS Parameter Format

The PDS and MINIMUM parameters are optional, but if one is specified, the other is mandatory.
PDS specifies a data set name of 1 through 44 characters.

General Information
The data set must be cataloged and it must be a partitioned data set.
The PDS cannot be used with the DAYS, WDAYS, MONTHS, CONFCAL, RETRO, and DATES parameters.
The PDS parameter is usually used to schedule a mission that will compress the library.
System libraries (such as SYS1.LINKLIB) should not be compressed using the standard compression
procedure. Therefore, BMC recommends that the WRN option of the TASKTYPE parameter be used.
Note: PDS does not work with PDSE-type libraries because they will always appear to be 100% full.

575
Control-M/Analyzer User Guide

Example
Check the ALL.PARMLIB library for a minimum of 20 unused tracks.
Figure 344 PDS Parameter Example
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS WCAL
MONTHS 1- 2- 3- 4- 5- 6- 7- 8- 9- 10- 11- 12-
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM 020 PDS ALL.PARMLIB
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

576
Control-M/Analyzer User Guide

PRIORITY: Mission Definition Parameter


For future use.
Figure 345 PRIORITY Parameter Format

577
Control-M/Analyzer User Guide

RETRO: Mission Definition Parameter


Enables a mission to be scheduled after its original scheduling date has passed.
Figure 346 RETRO Parameter Format

Optional. Valid values are:


 Y (Yes)
 N (No). Default.

General Information
The RETRO parameter is used to control situations where the computer has not been working for a day or
more due to holiday or hardware failure, and so on.
When such situations occur, it is necessary to instruct Control-M/Analyzer whether the mission should be
retroactively scheduled for the days when the computer (or Control-M/Analyzer) was inactive.
When RETRO=Y, missions are placed on the Active Balancing file for all the days the mission should have
been originally scheduled. Scheduling occurs from the last scheduling date to the current working date,
provided that those days were included in one of the scheduling parameters DAYS, DCAL, and so on. Each
mission placed on the Active Balancing file is associated with a different original scheduling date.
When RETRO=N, the mission is only scheduled for the current working date, provided that the mission is
normally scheduled for that date.
The RETRO parameter cannot be used with the MINIMUM and PDS parameters.

578
Control-M/Analyzer User Guide

Examples
Example 1
Schedule the balancing mission only on specific dates in the month. If the date has passed, do not
schedule the mission.
Figure 347 RETRO Parameter – Example 1
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS 15,16,18,19,20 DCAL
AND/OR
WDAYS WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

Assume that the computer was off line from the 16th until the 18th, and the 15th was the last date that
the mission was scheduled for execution. Today is the 19th. Therefore, the mission is only scheduled for
execution on the 19th.

579
Control-M/Analyzer User Guide

Example 2
Schedule the balancing mission for every working day, whether the computer is active or not.
Figure 348 RETRO Parameter – Example 2
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL WORKDAYS
AND/OR
WDAYS WCAL
MONTHS 1- N 2- N 3- N 4- N 5- N 6- N 7- N 8- N 9- N 10- N 11- N 12- N
DATES
CONFCAL SHIFT RETRO Y MAXWAIT 00
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

Assume that the computer was off line from the 16th until the 18th, and the 15th was the last date that
the mission was scheduled for execution. Today is the 19th.
Assume that the WORKDAYS calendar contains the dates 15, 16, 18, and 19. Therefore, the mission is
scheduled three times with the original scheduling dates: the 16th, 18th, and 19th.

580
Control-M/Analyzer User Guide

RULELIB: Mission Definition Parameter


Names the library where the rule specified in the RULENAME parameter is located.
Figure 349 RULELIB Parameter Format

Mandatory. RULELIB must specify a valid data set name of 1 through 44 characters. No blanks (except
trailing blanks) are allowed.

General Information
The library may be any standard partitioned data set. The record length must be 80.
The library does not have to exist when the parameters are defined. Rule existence is checked by
Control-M/Analyzer during execution of the balancing mission.

Example
Figure 350 RULELIB Parameter Example
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-----(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

581
Control-M/Analyzer User Guide

RULENAME: Mission Definition Parameter


Specifies the name of the rule to be executed.
Figure 351 RULENAME Parameter Format

Mandatory. RULENAME specifies a rule name of 1 through 8 characters. No blanks (except trailing blanks)
are allowed.

General Information
Every balancing mission is associated with a rule that performs the actual balancing tasks. The associated rule is
specified in the RULENAME parameter.
The rule definition contains specific balancing information, such as the type of data to be balanced and balancing
criteria. For more information about rule definition parameters, see Rule Definition (on page 348).

Example
Figure 352 RULENAME Parameter Example
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-----(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

582
Control-M/Analyzer User Guide

SCOPE: Mission Definition Parameter


Specifies to what extent the mission is accessible for Control-M/Analyzer invocations.
Figure 353 SCOPE Parameter Format

Mandatory. The default value is SINGLE.


SCOPE defines the search method Control-M/Analyzer uses when scanning the Active Balancing file for
the appropriate mission to execute. There are four possible SCOPE values:
 SINGLE
 STEP
 JOB
 ALL

General Information
When Control-M/Analyzer is invoked, the Active Balancing file is scanned for corresponding mission
entries, those entries with mission names that match the MISSION parameter. Corresponding mission
entries are then checked further to determine which mission to execute. The SCOPE parameter helps
determine which entries match the specified JOB and STEP specifications.
Valid SCOPE values are shown in Table 286.

583
Control-M/Analyzer User Guide

Table 286 SCOPE Parameter Values

Value Description

SINGLE If JOB and STEP values match, the mission entry is eligible for
further checking only if it has not been executed before. SINGLE
guarantees that this mission entry is only executed once – by a
single Control-M/Analyzer invocation.

STEP If JOB and STEP values match, the mission entry is eligible for
further checking if it has not been executed before, or it was
previously executed by the current STEP in the current JOB. STEP
enables the mission entry to be executed by several
Control-M/Analyzer invocations, provided that the invocations all
originated from the same job step (for example, from an application
program that invokes Control-M/Analyzer from within a loop).

JOB If JOB and STEP values match, the mission entry is eligible for
further checking if it has not been executed before, or it was
previously executed by the current JOB. JOB enables the mission
entry to be executed by several Control-M/Analyzer invocations,
provided that the invocations all originated from the same job.

ALL If JOB and STEP values match, the mission entry is eligible for
further checking. ALL enables the mission entry to be executed by
any or all Control-M/Analyzer invocations regardless of the jobs and
steps that previously initiated the entry.

For additional information on the Active Balancing file search method, see Invoking the
Control-M/Analyzer Runtime Environment (on page 41).

584
Control-M/Analyzer User Guide

Example
Figure 354 SCOPE Parameter Example
---- CONTROL-M/ANALZYER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

585
Control-M/Analyzer User Guide

SET VARS: Mission Definition Parameter


For future use.
Figure 355 SET VARS Parameter Format

586
Control-M/Analyzer User Guide

STEP: Mission Definition Parameter


Specifies one or two job steps from that the mission can be invoked.
Figure 356 STEP Parameter Format

Optional, unless the SCOPE parameter is set to the value STEP. Maximum length: 8 characters. Mask
characters may be specified in the STEP name.

General Information
When Control-M/Analyzer is invoked, the Active Balancing file is scanned for corresponding mission
entries, those entries with mission names that match the MISSION parameter. Corresponding mission
entries are then checked further to determine which mission to execute. The step name specified by the
invoking job step should match the STEP parameter. For additional information on the Active Balancing
file search method see Invoking the Control-M/Analyzer Runtime Environment (on page 41).
Job Step Prefixing
The STEP field can contain an asterisk (*) as the last character. Any step name with the specified prefix
will match.

587
Control-M/Analyzer User Guide

Example
Figure 357 STEP Parameter Example
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP STEP01 , STEP02 SCOPE STEP
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN
TIME FROM TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.12.25

588
Control-M/Analyzer User Guide

TIME: Mission Definition Parameter


Sets time limits (from, to) for mission execution.
Figure 358 TIME Parameter Format

Optional. FROM and TO must be in hhmm format (where hh is the hour and mm is the minute).
Example
2101 = 09:01 p.m.
0301 = 03:01 a.m.

TIME can be specified in the following ways:


TIME FROM hhmm TO
TIME FROM TO hhmm
TIME FROM hhmm TO hhmm

General Information
Control-M/Analyzer activates the mission only during the time range defined in the TIME parameter.
Mission entries with a TIME range that does not include the current time are not considered in the scan of
the Active Balancing file.
The mission is only executed from (but not before) the FROM time and up to (but not after) the TO time.
If either FROM or TO is not specified, the starting time of the Control-M/Analyzer working day is used as
the default.
If both FROM and TO are blank, no time limits are assumed.

589
Control-M/Analyzer User Guide

Examples
Example 1
Execute the balancing mission only between 9 p.m. and 6 a.m.
Figure 359 TIME Parameter – Example 1
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN
TIME FROM 2100 TO 0600 NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

Example 2
Start executing the balancing mission no later than 0700 in the morning:
TIME=(,0700)

590
Control-M/Analyzer User Guide

Example 3
Start executing the balancing mission after midnight:
Figure 360 TIME Parameter – Example 3
---- CONTROL-M/ANALYZER CATEGORY DAILY BAL MISSION INVENTORY-------(BM.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
CATEGORY DAILY MISSION INVENTORY
JOB INV STEP , SCOPE JOB
RULENAME INV01 RULELIB CTB.PROD.RULES
OWNER M43 GROUP INVENTORY
DESC END-OF-DAY INVENTORY CHECK
DOCMEM INV DOCLIB PROD.CTB.DOC
===========================================================================
DAYS DCAL
AND/OR
WDAYS ALL WCAL
MONTHS 1- Y 2- Y 3- Y 4- Y 5- Y 6- Y 7- Y 8- Y 9- Y 10- Y 11- Y 12- Y
DATES
CONFCAL SHIFT RETRO N MAXWAIT 00
MINIMUM PDS
===========================================================================
IN
TIME FROM 0000 TO NOT LATER THAN PRIORITY
===========================================================================
SET VARS
======= >>>>>>>>>> END OF BALANCING PARAMETERS FOR THIS CATEGORY <<<<<<< ======
USE THE DOC COMMAND TO SHOW/HIDE BALANCING DOCUMENTATION 10.01.10

591
Control-M/Analyzer User Guide

WDAYS: Mission Definition Parameter


Specifies days of the week on which the mission is ordered.
For more information see also DAYS and CONFCAL.
Figure 361 WDAYS Parameter Format

Optional. The WDAYS parameter specifies days of the week on which missions should be scheduled,
provided other basic scheduling criteria are met.
Values for WDAYS can be specified by themselves, or together with a calendar specified in the WCAL.
WDAYS or WCAL subparameter can also be specified in conjunction with DAYS and DCAL (described in
DAYS: Mission Definition Parameter (on page 542)).
WDAYS subparameters are described in Table 287.
Table 287 WDAYS Subparameters

Subparameter Description

WDAYS Days of each week in the month on which to schedule a mission.


(The months in which to schedule missions are specified in the
MONTHS parameter, described in MONTHS: Mission Definition
Parameter (on page 570)) Various formats (described later) can be
used to specify WDAYS (for example, 3 means the 3rd day of the
week, L2 means the day before the last day of the week).

Note: Start of the week depends on IOA Installation parameters


specifying whether 1=Sunday or 1=Monday. To discover your site
standard, contact your INCONTROL administrator. All references
below assume 1=Monday, 2=Tuesday, and so on. The last day of
the week is always coded zero (0).

592
Control-M/Analyzer User Guide

Subparameter Description

WCAL Name of a calendar containing a predefined set of dates (referred to


as working days) on that a mission should be scheduled. A specified
value must be a valid member name of 1-8 characters or an * to
indicate that the calendar specified in the CONFCAL parameter
should be used for scheduling. For more information about how to
define, use and modify calendars, see IOA Calendar Facility (on
page 204).

Note: A calendar specified in WCAL does not have to exist when


defining the mission. However it must exist when the mission is
ordered.

Assuming all other basic scheduling criteria are met


 when WDAYS are specified without WCAL, the mission is scheduled on the specified days of the week
 when WCAL is specified without WDAYS, the mission is scheduled on the working days marked in the
WCAL calendar
 when WDAYS and WCAL are both specified, scheduling depends on the combination of working days
defined in the calendar and the values and format of the WDAYS parameter (described below)
 when both DAYS and WDAYS criteria are specified, scheduling depends on the connecting AND/OR
value specified. For more information, see the AND/OR subparameter in the DAYS parameter.

Valid Formats for WDAYS


Valid formats for the WDAYS parameter, and how they relate to WCAL, are described below.
Non-periodic scheduling

593
Control-M/Analyzer User Guide

The following rules govern the use of non-periodic scheduling formats:


 n is an integer from 0 through 6, where 1 is the first day of the week (Sunday or Monday, depending
on the standards at your site) and 0 is the last day of the week (meaning, Saturday or Sunday).
 Multiple values can be specified (separated by commas) in any order.
 If a calendar name is specified for WCAL, it should not designate a periodic calendar.
Table 288 Non-Periodic Scheduling Formats

Format Description

ALL All days in the week. If ALL is specified, other WDAYS values cannot
be specified with it.
 If a WCAL calendar is not defined, schedule the rule on all days
in the week.
 If a WCAL calendar is defined, schedule the rule only on the
working days indicated in the calendar.

n,... Specific days of the week.


 If a WCAL calendar is not defined, schedule the rule on the
specified days.
 If a WCAL calendar is defined, schedule the rule only when a
day is defined as a working day in both the WDAYS and the
WCAL parameters.

+n,... Days of the week in addition to the working days specified in the
WCAL calendar. WCAL is mandatory.

–n,... Order the rule on all days except the nth day from the beginning of
the week. WCAL is mandatory.

>n,... Order the rule on the indicated day if it is a working day in the
WCAL calendar; otherwise, order the rule on the next working day
(within the next seven days) that is not negated by a –n value in
the parameter. If none of the next seven days is a working day, the
rule is not ordered. This format is frequently used for holiday
handling. WCAL is mandatory.

<n,... Order the rule on the indicated day if it is a working day in the
WCAL calendar; otherwise, order the rule on the last previous
working day (within the preceding seven days) that is not negated
by a –n value in the parameter. If none of the preceding seven days
was a working day, the rule is not ordered. This format is frequently
used for holiday handling. WCAL is mandatory.

Dn,... Order the rule on the nth working day from the beginning of the
week. WCAL is mandatory.

594
Control-M/Analyzer User Guide

–Dn,... Order the rule on all working days except the nth working day from
the beginning of the week. WCAL is mandatory.

Ln,... Order the rule on the nth working day from the end of the week.
WCAL is mandatory.

–Ln,... Order the rule on all working days except the nth working day from
the end of the week. WCAL is mandatory.

DnWm,... (Where m=1–6). If WCAL is defined, order the rule on the nth day
of the mth week of the month. If WCAL is not defined, order the
rule on the mth appearance of the nth day of the week during the
month. WCAL is optional.

Note: When specifying DnWm with a calendar in the WCAL field, do


not code n as 0. This may produce unpredictable results.

Periodic scheduling
The following rules govern the use of periodic scheduling formats:
 n is any integer from 0 through 6, and i is any valid period identifier (or * for all periods).
 WDAYS period identifiers are counted on a week by week basis. Calculations do not cross week
boundaries (unlike DAYS periodic identifiers that do cross month boundaries).
 The name of a periodic calendar must be specified in WCAL.
 A maximum of eight periodic values can be designated in any desired order.
Table 289 Periodic Scheduling Formats

Format Description

DnPi,... Order the rule on the nth day of period i in each week, from the
beginning of the week.

–DnPi,... Order the rule on all days except the nth day of period i in each week,
from the beginning of the week.

LnPi,... Order the rule on the nth day of period i in each week, from the last day
of the week.

–LnPi,... Order the job on all days in period i except the nth day of period i in
each week, from the last day of the week.

595
Control-M/Analyzer User Guide

General Information
Negative values take precedence over positive values when determining whether a mission is scheduled
on a certain date. If a negative value (for example, format –n, –Dn, –Ln, –DnPi, or –LnPi) in either the
DAYS or WDAYS field prevents a mission from being scheduled on a date, the mission will not be
scheduled on that date even if a positive value (for example, Ln) would otherwise result in the mission
being scheduled on that date.
A maximum of eight periodic values (for example, of types DnPi, –DnPi, LnPi, and –LnPi) can be
designated in any desired order.
If periodic and non-periodic values are mixed when specifying parameter WDAYS, processing will depend
on the calendar type specified in parameter WCAL.
 If a non-periodic calendar is specified in the WCAL parameter, only non-periodic values in the WDAYS
parameter are processed. Periodic values are ignored. In this case, negative periodic values (for
example, –DnPi, –LnPi) are also ignored and do not supersede other values.
 If a periodic calendar is specified in the WCAL parameter, all periodic values and the negative
non-periodic value -n in the WDAYS parameter are processed; all nonnegative non-periodic values are
ignored.
The MONTHS parameter is ignored when periodic values are specified in the WDAYS or DAYS parameter.
The WDAYS parameter cannot be used with the PDS, MINIMUM, and DATES parameters.
When Ln and/or Dn values are specified in a week that overlaps two months, the MONTHS value of the
earlier month determines whether Dn or Ln values are applied in the week:
 If the first day of the week falls in a month with a MONTHS value of Y, all Dn and Ln values in that
week are applied, even those falling in the next or previous month, when that month has a MONTHS
value of N.
 If the first day of the week falls in a month with a MONTHS value of N, no Dn or Ln values in that
week are applied (not even if those falling in the next or previous month, when that month has a
MONTHS value of Y).

Examples
The examples in this chapter are based on the following assumptions:
 The current month is December 2001.
 Working days are defined in the WORKDAYS calendar that contains the following working days
(indicated by Y) for December 2001:
--S-------------S-------------S-------------S-------------S--
1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1
Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y

 The PERIDAYS periodic calendar contains the following periodic definition for December 2001. These
examples assume that all other days of this calendar are blank.
--S-------------S-------------S-------------S-------------S--
1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1 2 3 4 5 6 7 8 9 + 1
B C A A B B C A A B B C A A B B C A A B B

596
Control-M/Analyzer User Guide

 Start of the week is defined as Monday. Weeks start on the following dates in December 2001: 3rd,
10th, 17th, 24th, and 31st.
At the end of each example, asterisks in a December 2001 calendar indicate the days on which the
mission is scheduled.
Example 1
Schedule the mission on every Sunday and Monday.
WDAYS 0,1

The mission is scheduled on the days of the month indicated by an asterisk:

Example 2
Schedule the mission on all working days and on all Saturdays.
WDAYS +6
WCAL WORKDAYS

The mission is scheduled on the days of the month indicated by an asterisk:

Example 3
Schedule the mission every Sunday, if it is a working day. If Sunday is not a working day, schedule the
mission on the first preceding working day that is not a Friday.
WDAYS -5,<0
WCAL WORKDAYS

The mission is scheduled on the days of the month indicated by an asterisk:

Example 4
Schedule the mission on the 1st Monday of the 1st week.
WDAYS D1W1

The mission is scheduled on the days of the month indicated by an asterisk:

597
Control-M/Analyzer User Guide

Example 5
Schedule the mission on all working days except Mondays and Fridays.
WDAYS -D1,-L1
WCAL WORKDAYS

The mission is scheduled on the days of the month indicated by an asterisk:

Example 6
Each week, schedule the mission on the 1st day of period A in each week, and on all days of period B,
except the second day of period B in each week.
WDAYS D1PA,-D2PB
WCAL PERIDAYS

The mission is scheduled on the days of the month indicated by an asterisk:

Example 7
Schedule the mission on each Monday, and on the 1st day of the month.
DAYS 1
AND/OR OR
WDAYS 1

The mission is scheduled on the days of the month indicated by an asterisk:

Example 8
Schedule the mission on the 3rd day of the month provided it is a Monday.
DAYS 3
AND/OR AND
WDAYS 1

The mission is scheduled on the days of the month indicated by an asterisk:

598
Control-M/Analyzer User Guide

Example 9
Schedule the mission on the last Monday of the month:
DAYS L1,L2,L3,L4,L5,L6,L7
AND/OR AND
WDAYS 1

The mission is scheduled on the days of the month indicated by an asterisk:

Example 10
Schedule the mission on the 1st, 7th and 15th day of the month if they are both Saturdays and working
days. If the day of the month (1st, 7th, 15th) is not a Saturday, do not schedule the mission. If the day of
the month is a Saturday, but it is not a working day, schedule the mission on the next working day.
DAYS 1,7,15
AND/OR AND
WDAYS 6
CONFCAL WORKDAYS
SHIFT >

The mission is scheduled on the days of the month indicated by an asterisk:

599
7
7
Reconciliation Facility
This chapter includes the following topics:
 Reconciliation Facility (on page 600)
 Reconciliation Stages (on page 601)
• Stage 1. Preparation (Mandatory) (on page 601)
• Stage 2. Merge (Optional) (on page 602)
• Stage 3. Sum (Optional) (on page 602)
 Reconciliation Work Flow (on page 603)
 Activating Program CTBRECL (on page 603)
 Reconciliation Functions (on page 604)
• WRITE (on page 604)
• SETKEY (on page 607)
• MERGE (on page 609)
• MERGEX (on page 612)
• SUM (on page 615)
• SUMX (on page 617)
 DD Statements (on page 621)
 Return Codes (on page 622)

Reconciliation Facility
Control-M/Analyzer includes a Reconciliation facility that can be used to
 reconcile data from two different sources
Comparing data from two different sources (for example, files) is an integral aspect of data balancing.
A typical example is check reconciliation: A check register, updated on-line by a clerk as each check is
written, is periodically compared to an automatically generated bank statement. Two files are involved
in the process:
• check register – record of checks as they are issued
• bank statement – record of checks that cleared the bank during the week or month
Reconciliation is necessary to verify that the data from both sources match.
The sequence of the two files is not identical. The check register is typically in check number order.
The bank statement is typically in clearance date order.

600
Control-M/Analyzer User Guide

The Control-M/Analyzer Reconciliation facility verifies that each check that appears in one file also
appears in the other and that the check amounts are identical. Control-M/Analyzer prints out
non-matching checks.
 facilitate processing of large files by providing summary records
A typical example involves a large sequential file that must be checked. Each record in the file belongs
to one of a hundred categories. Control-M/Analyzer summarizes the records by category and prints
out the total amount for each category.
The Control-M/Analyzer Reconciliation facility is implemented by the CTBRECL program that is invoked
through a DO CALLUSER statement. For a full description of the DO CALLUSER statement, see DO
CALLUSER: Automated Balancing Statement (on page 371).

Reconciliation Stages
A typical reconciliation scenario consists of the following stages. Use this explanation as a model for
identifying the stages in the reconciliation process at your site.

Stage 1. Preparation (Mandatory)


In this stage, a record key is identified. Based on this record key, the files involved in the process are
sorted and brought into a "canonical" structure (for example, placed in user requested order and
restructured). This stage can be performed using the WRITE or SETKEY Reconciliation function.

Example 1
Assume two files must be reconciled – a check register and a bank statement. The check register file
includes the account number, check number, check date, check amount, and payee for each check. The
bank statement file includes the bank name, account number, date received, check number, check
amount, and check date.
We instruct the Reconciliation facility to identify the check number as the key because this number exists
uniquely in both files. The two files are then sorted by check number. The check amount and check date
are retained as additional information.
The preparation stage is performed using the WRITE function. The WRITE function is used when the two
files being compared are in different formats (for example, have different record layouts).

Example 2
Assume two files – a check register (described above in Example 1) and an application report containing
the total sum value based on a bank statement report. We need to verify if the total sum is correct. Only
the check register needs to be reconciled. Therefore, the preparation stage is performed by the SETKEY
function that describes the record layout of the check register.
Note: Either the WRITE function or the SETKEY function can be specified for the preparation stage. Both
functions cannot be specified during the same reconciliation process.

601
Control-M/Analyzer User Guide

Stage 2. Merge (Optional)


The next stage can be performed on one or more files, depending on the Preparation function previously
used. If the WRITE function was used with two files, unmatched records can be detected.
The output of this stage can be
 unmatched records, for example, records that appear in one file but not the other
 all records, for example, both matched and unmatched records, sorted in key order
The merge stage is performed using the MERGE function (all records are included in the output) or
MERGEX (the user can request separate output files for matched and unmatched records). These
functions are explained in Reconciliation Functions (on page 604).

Stage 3. Sum (Optional)


The sum stage is an integral part of the reconciliation process that facilitates the processing of large files
by producing summary records. This stage can be performed on one or more files, depending on the
Preparation function previously used. If the WRITE function was used with two files, unmatched summary
records can be detected.
The output of this stage can be
 unmatched records, for example, records that appear in one file but not the other
 all records, for example, both matched and unmatched records, sorted in key order
The sum stage is performed using the SUM function (all summary records are included in the output) or
SUMX (the user can request separate output files for matched and unmatched records). These functions
are explained in Reconciliation Functions (on page 604).

Example
Assume two files exist:
 a summary report file contains three records per customer listing subtotals for local, long distance,
and international calls
 a detail file lists all phone calls for each customer
First, the records in the detail file are sub-totaled by customer. Then, these subtotals are compared to the
subtotals for each customer in the summary report file.
Note: The MERGEX and SUMX functions cannot be invoked if the SETKEY function was specified in the
Preparation stage.

602
Control-M/Analyzer User Guide

Reconciliation Work Flow


Figure 362 Reconciliation Work Flow

Stage 1 is mandatory (for example, the WRITE or SETKEY function must be performed in preparation for
the reconciliation). The WRITE function is performed once on each file. The SETKEY function is performed
once for all files simultaneously.
Either Stage 2 or Stage 3 is then performed, depending upon the type of reconciliation.

Activating Program CTBRECL


The basic format for activating the CTBRECL program is:
DO CALLUSER = CTBRECL ARG <RECONCILIATION FUNCTION>, <LIST OF PARAMETERS>

Depending upon the reconciliation function specified, different parameters must be specified. A detailed
description of each reconciliation function and its corresponding parameters is provided below.
Note: The maximum number of parameters that can be passed to the CTBRECL program is 50. For a full
description of the DO CALLUSER statement, see DO CALLUSER: Automated Balancing Statement (on page
371).

603
Control-M/Analyzer User Guide

Reconciliation Functions
You can specify one of the reconciliation functions described in Table 290 when activating the CTBRECL
program.
Table 290 Reconciliation Functions

Function Description

WRITE Defines the input file record structure and restructures the fields in
user-defined order.

SETKEY Defines the key of the input file records to be used by the
Control-M/Analyzer Reconciliation facility.

MERGE Sorts the files involved in the reconciliation process and merges the
files into one combined output file.

MERGEX Sorts the files involved in the reconciliation, merges them, and
produces the unmatched records as output.

SUM Sorts the input files involved in the reconciliation process, sums
(subtotals) the records in each file by key, and merges the records
into a combined output file.

SUMX Sorts the input files involved in the reconciliation process, sums
(subtotals) records in each file by key, merges the records into a
combined output file, and produces the unmatched records as
output.

WRITE
The WRITE reconciliation function enables the user to define a canonical (ordered, sorted) file structure to
the Reconciliation facility. The WRITE function performs Stage 1, the Preparation stage, of the
Reconciliation facility.
The WRITE function should be performed when
 comparing two files whose keys are not in the same position or format, for example, the record layout
of each file is essentially different
 the MERGEX or SUMX function will be performed during the same reconciliation
The WRITE function must be performed separately on each file being reconciled. Each file is allocated and
processed using ON and WHEN statements.
Note: The SETKEY function can also perform Stage 1 of the reconciliation. For instructions on when to use
the SETKEY function, see SETKEY (on page 607).

604
Control-M/Analyzer User Guide

Syntax
DO CALLUSER = CTBRECL ARG recfunc, fileid, argnum, keylen1, keyvar1, ..., key-end-mark,
len1, var1, ...

Arguments
All arguments passed to the CTBRECL program must be predefined Control-M/Analyzer Local variables, for
example, the values must be assigned before activating the CTBRECL program.
Table 291 Reconciliation Function WRITE Arguments

Argument Description

recFunc Reconciliation function to be used when specifying program


CTBRECL. Set the value of Control-M/Analyzer Local variable recfunc
to WRITE before invoking a DO CALLUSER statement. Mandatory.

fileId Identifier of the file to be processed. Set the value of


Control-M/Analyzer Local variable fileid to 1 or 2. Mandatory.

argNum Total number of all keyVar, keyLen, var, and len arguments
specified in this DO CALLUSER statement plus one (for argument
key-end-mark). argNum must be a Control-M/Analyzer Local
variable with a value that is numeric and odd. Mandatory.

keyLen Length of its corresponding argument keyVar (see below) in bytes.


keyLen must be a Control-M/Analyzer Local variable with a numeric
value.

keyVar Key field with which to build the canonized (ordered, sorted) file.
keyvar is usually extracted from the current file being processed.
Must be a Control-M/Analyzer Local variable.

Note: At least one keyLen and keyVar pair must be specified. The number of keyLen and
keyVar pairs is the maximum number of arguments that can be specified in a DO CALLUSER
statement. For details, see DO CALLUSER: Automated Balancing Statement (on page 371).

605
Control-M/Analyzer User Guide

Argument Description

keyEndMark Marker that indicates the end of the list of paired keyLen and
keyVar arguments. key-end-mark is specified immediately after all
keyLen and keyVar pairs and before all the len and var pairs in the
DO CALLUSER statement. Must be a Control-M/Analyzer Local
variable. The value of keyEndMark must be 0 (zero). Mandatory.

len Length of its corresponding argument var (see below) in bytes. len
must be a Control-M/Analyzer Local variable with a numeric value.

var Field that is available for information purposes, for example, not
part of the key. var is usually extracted from the current file being
processed. Must be a Control-M/Analyzer Local variable.

Note: The number of len and var pairs is limited by the maximum number of arguments
that can be specified in a DO CALLUSER statement. For details, see DO CALLUSER:
Automated Balancing Statement (on page 371).

General Information
The resulting format of the record generated by the WRITE function and referenced by the SORTIN
DD statement is:

keyVar1 keyVar2 keyVar3 ... fileId var1 var2 var3 ...

where

<------ Sum of all key lengths -----> 1 byte <----- Sum of all lengths ----->

Note: The WRITE function requires a preexisting work file referenced by the SORTIN DD statement. The
LRECL (record length allocation parameter) for this work file must be equal to or greater than the sum of
all keyLen values + len values + 1 (as defined above).

Invocation Results
The SYSURC system variable indicates the results of invoking the CTBRECL program. A zero value in
SYSURC indicates successful completion of the stage. For a full explanation of CTBRECL return codes, see
Return Codes (on page 622).

Example
Assume that an input file contains fields for account numbers, check numbers, check dates, check
amounts, and payees. The key field (for example, the field that uniquely identifies each check) is the
check number (seven characters). The check amount (nine characters) and check date (nine characters)
are also included in the output.

606
Control-M/Analyzer User Guide

In the rule illustrated below


 the first block, SETUP, initializes the variables necessary for performing the Preparation stage using
the WRITE function
 the next block, WRITE1, performs the WRITE function on the input file. The key is the check number
of each record
 subsequent blocks perform the MERGE function that is presented on the following pages
Variable L0, which contains the numeric value 0, identifies the end of the record key. The record key is
later used to determine whether two records are identical.
Figure 363 Reconciliation Function WRITE Example
LIBRARY : CTB.PROD.RULES RULE : CANONIZ
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M43 GROUP BANKING_DIVISION
UPDATED 08/08/00 - 15:23:24 BY M43
DESC CALLS RECONCILIATION FACILITY TO CANONIZE A FILE
OPTIONS
===========================================================================
EXECUTE SETUP UPON C
ON DATA
ALWAYS
DO SET = RECFUNC='WRITE' C
DO SET = FILE1=1 C
DO SET = FILE2=2 C
DO SET = L7=7 C
DO SET = L9=9 C
DO SET = L0=0 C
DO SET = ARGNUM=7 C
===========================================================================
EXECUTE WRITE1 UPON C
ON FILE FILENAME BANK.REGISTER
MODE DS LINECT 0000 DATASTAMP
WHEN LINE 001 - 999 COL 001 - 001 STOP AND/OR
STRING = .AL.
DO EXTRACT = CHECKNUM
LEVEL 0 LINE +000 COL 0010 - 0016 PROCESS TYP
DO EXTRACT = CHECKDATE
LEVEL 0 LINE +000 COL 0025 - 0033 PROCESS TYP
DO EXTRACT = CHECKAMT
LEVEL 0 LINE +000 COL 0040 - 0048 PROCESS TYP
DO CALLUSER = CTBRECL ARG RECFUNC,FILE1,ARGNUM,L7,CHECKNUM,L0,L9, C Y
CHECKAMT,L9,CHECKDATE C
===========================================================================
PLEASE FILL IN RULE DEFINITION. 15.23.55

SETKEY
The SETKEY reconciliation function defines the record key of the records to be used by the Reconciliation
facility. The SETKEY function defines the record key for files that have similar record layouts, for
example, the key fields can be identified without any further processing.
The SETKEY or WRITE function can be run to perform Stage 1, the Preparation stage, of the
Reconciliation facility.
The SETKEY function should be run when
 reconciling one (usually large) existing input file – for example, to produce summary records
In this case, the SETKEY function can be performed on the file without merging afterward

607
Control-M/Analyzer User Guide

 comparing or summing files with the same record layout


The MERGEX function and the SUMX function cannot be performed when the SETKEY function is used.
Note: The WRITE function also performs Stage 1 of the reconciliation. For instructions on when to use the
WRITE function, see WRITE (on page 604).
The input file for the SETKEY function should be referenced by the SORTIN DD statement. A work file is
not required when using the SETKEY function. However, the SORTIN DD statement must reference the
original file to be reconciled. Several input files may be concatenated through this DD statement if they
have identical record layouts.
The SETKEY function expects pairs of offset and length parameters as input, and uses these parameters
to define the record key. The record key is later used to determine whether two records are identical.

Syntax
DO CALLUSER = CTBRECL ARG recFunc, argNum, offset1, len1, offset2, len2, ...

Arguments
All arguments passed to the CTBRECL program must be predefined Control-M/Analyzer Local variables.
For example, the values must be assigned before activating the CTBRECL program.
Table 292 SETKEY Reconciliation Function Arguments

Argument Description

recFunc Reconciliation function to be used when specifying program


CTBRECL. Set the value of Control-M/Analyzer Local variable
recFunc to SETKEY before invoking the DO CALLUSER statement.
Mandatory.

argNum Number of offset and length arguments specified in this DO


CALLUSER statement. argNum must be a Control-M/Analyzer Local
variable with a numeric, even value. Mandatory.

offset Starting position of the corresponding record key in the file being
processed (for example, if the starting position is the left-most
column in a record, set the value of offset to 1). Must be a
Control-M/Analyzer Local variable with a numeric value.

len Length of the corresponding record key in bytes. len must be a


Control-M/Analyzer Local variable with a numeric value.

Note: At least one offset and len pair must be specified. The number of offset and len pairs
is limited by the maximum number of arguments that can be specified in a DO CALLUSER
statement. For details, see DO CALLUSER: Automated Balancing Statement (on page 371).

608
Control-M/Analyzer User Guide

Invocation Results
The SYSURC stem variable indicates the results of invoking the CTBRECL program. A zero value in
SYSURC indicates successful completion of the stage. For a full explanation of CTBRECL return codes, see
Return Codes (on page 622).

Example
Assume a file includes a transaction code in columns 17 to 23 (7 characters in length), and a transaction
amount in columns 30 to 38 (9 characters in length). These two fields comprise the record key.
The Control-M/Analyzer rule below illustrates how to define this key to the Control-M/Analyzer
Reconciliation facility.
The first block, SETKEY, initializes the variables necessary for performing the Preparation stage through
the SETKEY function and performs this function on the file.
Subsequent blocks perform the reconciliation.
Figure 364 Reconciliation Function SETKEY Example
LIBRARY : CTB.PROD.RULES RULE : SETKEY
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M43 GROUP BANKING_DEPARTMENT
UPDATED 08/08/00 - 15:32:32 BY M43
DESC RECONCILIATION FACILITY SETS KEY FIELDS
OPTIONS
===========================================================================
EXECUTE SETKEY UPON C
ON DATA
ALWAYS
DO SET = RECFUNC='SETKEY' C
DO SET = LEN1=7 C
DO SET = LEN2=9 C
DO SET = OFFSET1=17 C
DO SET = OFFSET2=30 C
DO SET = ARGNUM=4 C
DO CALLUSER = CTBRECL ARG RECFUNC,ARGNUM,OFFSET1,LEN1,OFFSET2,LEN2 C
===========================================================================
EXECUTE RECONCIL UPON C
ON DATA
PLEASE FILL IN RULE DEFINITION. 15.32.29

MERGE
If more than one input file is involved in the reconciliation process, the MERGE function sorts the files
involved and merges them into one output file referenced by the SORTOUT DD statement.
The Preparation stage, using either the WRITE or SETKEY function (but not both), must precede the
Merge stage. The output of the WRITE function, or the original input file when using the SETKEY function,
is the input for the MERGE function.
The output of the MERGE function is a file containing all the records from the original files. The SORTOUT
DD statement must be included in the job that invokes the reconciliation rule. For more information, see
DD Statements (on page 621).
The next block in the reconciliation rule is usually an ON DDNAME SORTOUT block that scans the output
of the MERGE function.

609
Control-M/Analyzer User Guide

Note: The SORTOUT file should be allocated with the same LRECL (record length parameter) as the
SORTIN file.

Syntax
DO CALLUSER = CTBRECL ARG recfunc

Arguments
All arguments passed to the CTBRECL program must be predefined Control-M/Analyzer Local variables.
For example, the values must be assigned before activating the CTBRECL program.
Table 293 MERGE Reconciliation Function Arguments

Argument Description

recFunc Reconciliation function to be used when specifying the CTBRECL


program. Set the value of the recFunc Control-M/Analyzer Local
variable to MERGE before invoking the DO CALLUSER statement.
Mandatory.

Invocation Results
The SYSURC system variable indicates the results of invoking the CTBRECL program. A zero value in
SYSURC indicates successful completion of the stage. For a full description of CTBRECL return codes, see
Return Codes (on page 622).

Example
The sample rule illustrated below specifies the following:
 The first block, SETUP, initializes variables for performing the Preparation stage using the WRITE
function.
 The next two blocks, WRITE1 and WRITE2, perform the WRITE function on both input files. The
check number is the key.
 The fourth block, MERGE, performs the MERGE function.
 The fifth block, TEST, prints out the check numbers.

610
Control-M/Analyzer User Guide

Figure 365 MERGE Reconciliation Function Example


LIBRARY : CTB.PROD.RULES RULE : MERGE2
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M43 GROUP BANKING_DEPARTMENT
UPDATED 08/08/00 - 15:32:32 BY M43
DESC RECONCILIATION FACILITY MERGES TWO FILES
OPTIONS
===========================================================================
EXECUTE SETUP UPON C
ON DATA
ALWAYS
DO SET = RECFUNC='WRITE' C
DO SET = FILE1=1 C
DO SET = FILE2=2 C
DO SET = L6=6 C
DO SET = L8=8 C
DO SET = L0=0 C
DO SET = ARGNUM=7 C
===========================================================================
EXECUTE WRITE1 UPON C
ON FILE FILENAME BANK.REGISTER1
MODE DS LINECT 0000 DATASTAMP
WHEN LINE 001 - 999 COL 001 - 001 STOP AND/OR
STRING = .AL.
DO EXTRACT = CHECKNUM
LEVEL 0 LINE +000 COL 0010 - 0015 PROCESS TYP
DO EXTRACT = CHECKDATE
LEVEL 0 LINE +000 COL 0025 - 0032 PROCESS TYP
DO EXTRACT = CHECKAMT
LEVEL 0 LINE +000 COL 0040 - 0047 PROCESS TYP
DO CALLUSER = CTBRECL ARG RECFUNC,FILE1,ARGNUM,L6,CHECKNUM,L0,L8, C Y
CHECKAMT,L8,CHECKDATE C
===========================================================================
EXECUTE WRITE2 UPON C
ON FILE FILENAME BANK.REGISTER2
MODE DS LINECT 0000 DATASTAMP
WHEN LINE 001 - 999 COL 001 - 001 STOP AND/OR
STRING = .AL.
DO EXTRACT = CHECKNUM
LEVEL 0 LINE +000 COL 0020 - 0025 PROCESS TYP
DO EXTRACT = CHECKDATE
LEVEL 0 LINE +000 COL 0030 - 0037 PROCESS TYP
DO EXTRACT = CHECKAMT
LEVEL 0 LINE +000 COL 0040 - 0047 PROCESS TYP
DO CALLUSER = CTBRECL ARG RECFUNC,FILE2,ARGNUM,L6,CHECKNUM,L0,L8, C Y
CHECKAMT,L8,CHECKDATE C
===========================================================================
EXECUTE MERGE UPON C
ON DATA
ALWAYS
DO SET = RECFUNC='MERGE' C
DO CALLUSER = CTBRECL ARG RECFUNC C
===========================================================================
EXECUTE TEST UPON C
ON DDNAME DDNAME SORTOUT
MODE DS LINECT DATASTAMP
WHEN LINE 001 - 999 COL 016 - 021 STOP AND/OR
STRING = 010198
DO EXTRACT = CHECKINFO
LEVEL LINE +000 COL 0008 - 0015 PROCESS TYP
DO PRINT = 'CHECK NUMBER %%CHECKINFO' F C
PLEASE FILL IN RULE DEFINITION. 15.39.33

611
Control-M/Analyzer User Guide

MERGEX
The MERGEX reconciliation function sorts the files involved in the reconciliation process, merges them into
one output work file, and produces the unmatched records as output.
The WRITE function of the Preparation stage must be performed on both files before the MERGEX stage
can be performed. The SETKEY function cannot be run in preparation for the MERGEX function.
The input file for the MERGEX function must be referenced by the SORTIN DD statement. The MERGEX
output work file must be referenced by the SRTOUT DD statement.
The output of the MERGEX function is a file containing only unmatched records. The output is referenced
by the SRECOUT1 DD statement that must be included in the job that invokes the reconciliation rule. For
more information, see DD Statements (on page 621). An optional output file, referenced by the
SRECOUT2 DD statement, includes all matched records from the original files. This optional output file is
produced if parameter match is set to YES and the SRECOUT2 DD statement is included in the job that
invokes the reconciliation rule.
The next block in the reconciliation rule is usually an ON DDNAME SRECOUT1 block that scans the
MERGEX output and prints a message for each unmatched record.

Syntax
DO CALLUSER = CTBRECL ARG recfunc, match

Arguments
All arguments passed to the CTBRECL program must be predefined Control-M/Analyzer Local variables.
For example, the values must be assigned before activating the CTBRECL program.
Table 294 MERGEX Reconciliation Function Arguments

Function Description

recfunc Reconciliation function to be used when specifying the CTBRECL


program. Set the value of the recFunc Control-M/Analyzer Local
variable to MERGEX before invoking a DO CALLUSER statement.
Mandatory.

match Flag that indicates whether matching records should also be listed.
Must be a Control-M/Analyzer Local variable. Mandatory.
 YES – Matching values should be listed in a separate file
referenced by SRECOURT2 DD statement. Unmatched records
are listed in a file referenced by the SRECOUT1 DD statement.
 NO – Matching values should not be listed. Unmatched records
are listed in a file referenced by the SRECOUT1 DD statement.

612
Control-M/Analyzer User Guide

Invocation Results
The SYSURC system variable indicates the results of invoking the CTBRECL program. A zero value in
SYSURC indicates successful completion of the stage. For a full description of CTBRECL return codes, see
Return Codes (on page 622).

Example
The sample rule below specifies the following:
 The first block, SETUP, initializes the variables necessary for performing the Preparation stage using
the WRITE function.
 The next two blocks, WRITE1 and WRITE2, perform the WRITE function on both files.
 The fourth block, MERGEX, sorts the files, merges them, and produces unmatched records as output
 The fifth block, OUTPUT, prints out the unmatched check information.

613
Control-M/Analyzer User Guide

Figure 366 MERGEX Reconciliation Function Example


LIBRARY : CTB.PROD.RULES RULE : MERGEX
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M43 GROUP BANKING_DIVISION
UPDATED 08/08/00 - 12:20:24 BY M43
DESC RECONCILIATION FACILITY MERGES TWO FILES
OPTIONS
===========================================================================
EXECUTE SETUP UPON C
ON DATA
ALWAYS
DO SET = RECFUNC='WRITE' C
DO SET = FILE1=1 C
DO SET = FILE2=1 C
DO SET = L6=6 C
DO SET = L8=8 C
DO SET = L0=0 C
DO SET = ARGNUM=7 C
===========================================================================
EXECUTE WRITE1 UPON C
ON FILE FILENAME BANK.REGISTER
MODE DS LINECT 0000 DATASTAMP
WHEN LINE 001 - 999 COL 001 - 001 STOP AND/OR
STRING = .AL.
DO EXTRACT = CHECKNUM
LEVEL 0 LINE +000 COL 0010 - 0015 PROCESS TYP
DO EXTRACT = CHECKDATE
LEVEL 0 LINE +000 COL 0025 - 0032 PROCESS TYP
DO EXTRACT = CHECKAMT
LEVEL 0 LINE +000 COL 0040 - 0047 PROCESS TYP
DO CALLUSER = CTBRECL ARG RECFUNC,FILE1,ARGNUM,L6,CHECKNUM,L0,L8, C Y
CHECKAMT,L8,CHECKDATE C
===========================================================================
EXECUTE WRITE2 UPON C
ON FILE FILENAME BANK.STATEMENT
MODE DS LINECT 0000 DATASTAMP
WHEN LINE 001 - 999 COL 001 - 001 STOP AND/OR
STRING = .AL.
DO EXTRACT = CHECKNUM
LEVEL 0 LINE +000 COL 0070 - 0075 PROCESS TYP
DO EXTRACT = CHECKDATE
LEVEL 0 LINE +000 COL 0015 - 0022 PROCESS TYP
DO EXTRACT = CHECKAMT
LEVEL 0 LINE +000 COL 0030 - 0037 PROCESS TYP
DO CALLUSER = CTBRECL ARG RECFUNC,FILE2,ARGNUM,L6,CHECKNUM,L0,L8, C Y
CHECKAMT,L8,CHECKDATE C
===========================================================================
EXECUTE MERGEX UPON C
ON DATA
ALWAYS
DO SET = RECFUNC='MERGEX' C
DO SET = MATCH='NO' C
DO CALLUSER = CTBRECL ARG RECFUNC,MATCH C
DO PRINT = 'FOLLOWING ARE THE MISMATCHED RECORDS: ' F C
===========================================================================
EXECUTE OUTPUT UPON C
ON DDNAME DDNAME SRECOUT1
MODE DS LINECT 0000 DATASTAMP
WHEN LINE 001 - 999 COL 001 - 001 STOP AND/OR
STRING = .AL.
DO EXTRACT = LINE
LEVEL 0 LINE +000 COL 0001 - 0070 PROCESS TYP
DO PRINT = %%LINE F C
PLEASE FILL IN RULE DEFINITION. 21.12.20

614
Control-M/Analyzer User Guide

SUM
The SUM reconciliation function sorts the files involved in the reconciliation process, sums identical key
records in the files, and merges the summed records into one output file referenced by the SORTOUT
DD statement.
The Preparation stage, using either function WRITE or SETKEY (but not both), must precede the Sum
stage. The output of the WRITE function, or the original input file when using the SETKEY function, is the
input for the SUM function.
The output of the SUM function is a file containing the summed records calculated from records in the
original files. The SORTOUT DD statement must be included in the job that invokes the reconciliation rule.
For more information, see DD Statements (on page 621).
The next block in the reconciliation rule is usually an ON DDNAME SORTOUT block that scans the output
of the SUM function.

Syntax
DO CALLUSER = CTBRECL ARG recFunc, argNum, offset1, len1, fldType1, offset2, len2,
fldType2, ...

Arguments
All arguments passed to the CTBRECL program must be predefined Control-M/Analyzer Local variables.
For example, the values must be assigned before activating the CTBRECL program.
Table 295 SUM Reconciliation Function Arguments

Argument Description

recFunc Reconciliation function to be used when specifying the CTBRECL


program. Set the value of the recFunc Control-M/Analyzer Local
variable to SUM before invoking the DO CALLUSER statement.
Mandatory.

argNum Number of offset, len, and fldType arguments specified in this DO


CALLUSER statement. argNum must be a Control-M/Analyzer Local
variable with a numeric value. Mandatory.

offset Starting position of the corresponding field to be summed in the file


being processed. For example, if the starting position is the
left-most column in a record, set the value of offset to one. Must be
a Control-M/Analyzer Local variable with a numeric value.

len Length of the corresponding field that should be totaled, starting at


the previous offset. Must be a Control-M/Analyzer Local variable
with a numeric value.

615
Control-M/Analyzer User Guide

Argument Description

fldType Type of the field to be totaled. Valid values are:.


 ZD—Signed, zoned decimal field
 PD—Packed decimal field
 BI—Signed binary field

Note: At least one offset-len-fldType set must be specified. The number of


offset-len-fldType sets is limited by the maximum number of arguments that can be
specified in a DO CALLUSER statement. Each set of these arguments specifies a field to be
summed.

Invocation Results
The SYSURC system variable indicates the results of invoking the CTBRECL program. A zero value in
SYSURC indicates successful completion of the stage. For a full explanation of CTBRECL return codes, see
Return Codes (on page 622).

Example
Assume that a file contains records that list customer transactions on Automatic Teller Machines (ATMs).
An automatic teller machine identifier (ATMID) is attached to each transaction, in columns 30 through 36.
We would like to subtotal the transaction amount field, a signed zoned decimal field in columns 20
through 27, by ATMID.
The sample rule below specifies the following:
 The first block, SETKEY, initializes the variables required by the SETKEY function and performs the
SETKEY function on the input file.
 The next block, SUM, initializes the variables necessary for performing the SUM function and performs
the SUM function on the file.
 The third block, TEST, prints the summed records.

616
Control-M/Analyzer User Guide

Figure 367 SUM Reconciliation Function Example


LIBRARY : CTB.PROD.RULES RULE : ATM
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M43 GROUP BANKING_DIVISION
UPDATED 08/08/00 - 12:45:24 BY M43
DESC
OPTIONS
===========================================================================
EXECUTE SETKEY UPON C
ON DATA
ALWAYS
DO SET = RECFUNC='SETKEY' C
DO SET = LEN1=7 C
DO SET = OFFSET1=30 C
DO SET = ARGNUM=2 C
DO CALLUSER = CTBRECL ARG RECFUNC,ARGNUM,OFFSET1,LEN1 C
===========================================================================
EXECUTE SUM UPON C
ON DATA
ALWAYS
DO SET = RECFUNC='SUM' C
DO SET = LEN=8 C
DO SET = OFFSET=20 C
DO SET = FLDTYPE='ZD' C
DO SET = ARGNUM=3 C
DO CALLUSER = CTBRECL ARG RECFUNC,ARGNUM,OFFSET,LEN,FLDTYPE C
DO PRINT = 'FOLLOWING ARE THE SUMMED RECORDS:' F C
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE TEST UPON C
ON DDNAME DDNAME SORTOUT
MODE DS LINECT 0000 DATASTAMP
WHEN LINE 001 - 999 COL 001 - 001 STOP AND/OR
STRING = .AL.
DO EXTRACT = LINE
LEVEL 0 LINE +000 COL 0001 - 0036 PROCESS TYP
DO PRINT = %%LINE F C
PLEASE FILL IN RULE DEFINITION. 12.21.20

SUMX
The SUMX reconciliation function does the following:
1. It sorts the files involved in the reconciliation process.
2. It sums identical key records in each file.
3. It merges the summed records into one output work file.
4. It produces an output file containing unmatched records.
5. Optionally, it produces another output file containing matched records.
The Preparation stage must be performed using the WRITE function on both input files before the SUMX
function can be performed. The SETKEY function cannot be run in preparation for the SUMX function.
The input file for the SUMX function must be referenced by the SORTIN DD statement. The output work
file for summed records must be referenced by the SORTOUT DD statement.
The output of the SUMX function includes a file containing all unmatched records. This output file is
referenced by the SRECOUT1 DD statement, which must be included in the job that invokes the
reconciliation rule. For more information, see DD Statements (on page 621).

617
Control-M/Analyzer User Guide

An optional output file, referenced by the SRECOUT2 DD statement, includes all matched records from the
original files. This optional output file is produced if parameter match is set to YES and the SRECOUT2
DD statement is included in the job that invokes the reconciliation rule.
The next block in the reconciliation rule is usually an ON DDNAME SRECOUT1 block that scans the SUMX
output and prints an error message for each unmatched summary record.

Syntax
DO CALLUSER = CTBRECL ARG recFunc, match, sumExcl, argNum, offset1, len1, fldType1, ...

Arguments
All arguments passed to the CTBRECL program must be predefined Control-M/Analyzer Local variables.
For example, the values must be assigned before activating the CTBRECL program.
Table 296 Reconciliation Function SUMX Arguments

Argument Description

recFunc Reconciliation function to be used when specifying the CTBRECL


program. Set the value of the recFunc Control-M/Analyzer Local
variable to SUMX before invoking the DO CALLUSER statement.
Mandatory.

match Flag that indicates whether matched records should also be listed.
Must be a Control-M/Analyzer Local variable. Mandatory. Valid
values are:
 YES – Matched records should be listed in a separate file
referenced by the SRECOUT2 DD statement. Unmatched
records are listed in a file referenced by the SRECOUT1
DD statement.
 NO – Matched records should not be listed. Unmatched records
are listed in a file referenced by the SRECOUT1 DD statement.

SumExcl This argument is reserved for future use. In the meantime, set
sumExcl to zero. Mandatory.

argNum Number of offset, length, and fldType arguments specified in this


DO CALLUSER statement. argNum must be a Control-M/Analyzer
Local variable with a numeric value. Mandatory.

offset Starting position of the corresponding field to be summed in the file


being processed. For example, if the starting position is the
left-most column in a record, set the value of offset to 1. Must be a
Control-M/Analyzer Local variable with a numeric value.

618
Control-M/Analyzer User Guide

Argument Description

len Length of the corresponding field that should be totaled, starting at


the previous offset. Must be a Control-M/Analyzer Local variable
whose value is numeric.

fldType Type of the field to be totaled. Valid values are:


 ZD – Signed, zoned decimal field
 PD – Packed decimal field
 BI – Signed binary field

Note: At least one offset-len-fldType set must be specified. The number of


offset-len-fldType sets is limited by the maximum number of arguments that can be
specified in a DO CALLUSER statement. Each set of these arguments specifies a field to be
summed.

Invocation Results
The SYSURC system variable indicates the results of invoking the CTBRECL program. A zero value in
SYSURC indicates successful completion of the stage. For a full explanation of CTBRECL return codes, see
Return Codes (on page 622).

Example
Assume that two files exist:
 The first file contains all ATM transaction records for a specific day.
 The second file contains summary amounts (totals) per ATM for that day.
We would like to total the records in the first file per ATM, and then compare these totals to the second
file. This will indicate if any ATM transactions are included in only one of the two files, but not both.
The sample rule below specifies the following:
 The first block, SETUP, initializes the variables needed to perform the WRITE function on each file.
 The next two blocks, WRITE1 and WRITE2, perform the WRITE function on the two files. These
blocks bring the two files to an ordered format, where ATMID comprises the record key.
 The fourth block, SUMX, initializes variables for the SUMX function and performs the SUMX function to
sum the transaction amounts by ATMID.
 The last block, TEST, prints the unmatched records that exist in only one of the two files.

619
Control-M/Analyzer User Guide

Figure 368 Reconciliation Function SUMX Example


LIBRARY : CTB.PROD.RULES RULE : ATM2
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M43 GROUP BANKING_DIVISION
UPDATED 08/08/00 - 12:58:24 BY M43
DESC
OPTIONS
===========================================================================
EXECUTE SETUP UPON C
ON DATA
ALWAYS
DO SET = RECFUNC='WRITE' C
DO SET = FILE1=1 C
DO SET = FILE2=2 C
DO SET = L6=6 C
DO SET = L8=8 C
DO SET = L0=0 C
DO SET = ARGNUM=5 C
===========================================================================
EXECUTE WRITE1 UPON C
ON FILE FILENAME ATM.FILE1
MODE DS LINECT 0000 DATASTAMP
WHEN LINE 001 - 999 COL 001 - 001 STOP AND/OR
STRING = .AL.
DO EXTRACT = ATMID
LEVEL 0 LINE +000 COL 0010 - 0015 PROCESS TYP
DO EXTRACT = TRANAMT
LEVEL 0 LINE +000 COL 0040 - 0047 PROCESS TYP
DO CALLUSER = CTBRECL ARG RECFUNC,FILE1,ARGNUM,L6,ATMID,L0,L8, C Y
TRANAMT C
===========================================================================
EXECUTE WRITE2 UPON C
ON FILE FILENAME ATM.FILE2
MODE DS LINECT 0000 DATASTAMP
WHEN LINE 001 - 999 COL 001 - 001 STOP AND/OR
STRING = .AL.
DO EXTRACT = ATMID
LEVEL 0 LINE +000 COL 0070 - 0075 PROCESS TYP
DO EXTRACT = TRANAMT
LEVEL 0 LINE +000 COL 0050 - 0057 PROCESS TYP
DO CALLUSER = CTBRECL ARG RECFUNC,FILE2,ARGNUM,L6,ATMID,L0,L8, C Y
TRANAMT C
===========================================================================
EXECUTE SUMX UPON C
ON DATA
ALWAYS
DO SET = RECFUNC='SUMX' C
DO SET = MATCH='NO' C
DO SET = LEN=8 C
DO SET = OFFSET=16 C
DO SET = FLDTYPE='ZD' C
DO SET = ARGNUM=3 C
DO SET = EXCL=0 C
DO CALLUSER = CTBRECL ARG RECFUNC,MATCH,EXCL,ARGNUM,OFFSET,LEN,FLDTY C Y
PE C
===========================================================================
EXECUTE TEST UPON C
ON DDNAME DDNAME SRECOUT1
MODE DS LINECT 0000 DATASTAMP
WHEN LINE 001 - 999 COL 001 - 001 STOP AND/OR
STRING = .AL.
DO EXTRACT = LINE
LEVEL 0 LINE +000 COL 0001 - 0070 PROCESS TYP
DO PRINT = %%LINE F C
PLEASE FILL IN RULE DEFINITION. 13.00.56

620
Control-M/Analyzer User Guide

DD Statements
The Reconciliation facility requires a number of DD statements that must be included in the JCL of the job
invoking the reconciliation rule:
Table 297 Required DD Statements for the Reconciliation Facility

Statement Description

SORTIN For the WRITE function: Temporary output of the function to be


used by a later stage.
For the SETKEY function: Input file on which the function operates.

SORTOUT Output of the MERGE and SUM functions. Work file for the MERGEX
and SUMX functions.

SRECOUT1 Output (unmatched records) of the MERGEX and SUMX functions.

SRECOUT2 Output (matched records) of the MERGEX and SUMX functions.


Produced only if parameter match is set to YES.

SORTWKnn Temporary work space files. The amount of work space required
depends on the number of records processed.

SYSOUT Output spool file for statistics and error messages.

Three sample JCL members that invoke a reconciliation rule are illustrated in the following examples.

Example 1
Figure 369 JCL Member that Invokes a Reconciliation Rule – Example 1
//... JOB ...
// EXEC CONTROLB,RULE=reconcile-rule
//SORTIN DD DSN=pre-allocated-file or temporary files,DISP=SHR
//SORTOUT DD DSN=empty-pre-allocated-file or temporary files,DISP=SHR
//SORTOUT1 DD DSN=empty-pre-allocated-file or temporary files,DISP=SHR
//SORTOUT2 DD DSN=empty-pre-allocated-file or temporary files,DISP=SHR
//SORTWK01 DD UNIT=SYSALLDA,SPACE=(TRK,(5,10))
//SORTWK02 DD UNIT=SYSALLDA,SPACE=(TRK,(5,10))
//SORTWK03 DD UNIT=SYSALLDA,SPACE=(TRK,(5,10))
//SYSOUT DD SYSOUT=held-class
//

621
Control-M/Analyzer User Guide

Example 2
This job invokes a rule that calls the WRITE and MERGEX functions. Output includes both matching and
non-matching records.
Figure 370 JCL Member that Invokes a Reconciliation Rule – Example 2
//... JOB ...
// EXEC CONTROLB,RULE=write and mergex
//SORTIN DD DSN=empty-pre-allocated-file,DISP=SHR
//SORTOUT DD DSN=empty-pre-allocated-file,DISP=SHR
//SRECOUT1 DD DSN=empty-pre-allocated-file,DISP=SHR
//SRECOUT2 DD DSN=empty-pre-allocated-file,DISP=SHR
//SORTWK01 DD UNIT=SYSALLDA,SPACE=(TRK,(5,10))
//SORTWK02 DD UNIT=SYSALLDA,SPACE=(TRK,(5,10))
//SORTWK03 DD UNIT=SYSALLDA,SPACE=(TRK,(5,10))
//SYSOUT DD SYSOUT=held-class
//

Example 3
This job invokes a rule that calls the SETKEY and SUM functions.
Figure 371 JCL Member that Invokes a Reconciliation Rule – Example 3
//... JOB ...
// EXEC CONTROLB,RULE=setkey and sum
//SORTIN DD DSN=our-input-file,DISP=SHR
//SORTOUT DD DSN=empty-pre-allocated-file,DISP=SHR
//SORTWK01 DD UNIT=SYSALLDA,SPACE=(TRK,(5,10))
//SORTWK02 DD UNIT=SYSALLDA,SPACE=(TRK,(5,10))
//SORTWK03 DD UNIT=SYSALLDA,SPACE=(TRK,(5,10))
//SYSOUT DD SYSOUT=held-class
//

Return Codes
The return codes that can be returned by the CTBRECL program are described in Table 298.
Table 298 Return Codes for Program CTBRECL

Code Description

0 Operation completed successfully (OK)

4 Invalid function requested


Correct the function name specified in the corresponding Local
variable, and rerun the rule.

8 Internal error
Contact your BMC Customer Support for assistance.

622
Control-M/Analyzer User Guide

Code Description

12 Memory allocation failed


Increase the value of parameter REGION specified in the job or step
JCL card, and rerun the rule.

16 Number of arguments is zero


The number of arguments specified in Local variable argnum is not
accurate. Correct this value and rerun the rule.

20 SORTIN file was not opened


Check the SORTIN DD statement for the job. Correct the JCL and
rerun the rule.

24 Record key length for the first file is different from key length of the
second file
The total key length (for example, the sum of the lengths of the key
fields) specified for the first file differs from the total key length
specified for the second file. Correct the length of the keys and
rerun the rule.

28 Work buffer not large enough


The CTBRECL routine is unable to continue processing. Contact
BMC Customer support for assistance.

32 Wrong file number in the WRITE reconciliation function


File number may be either 1 or 2 only. Correct the value of the
corresponding Local variable and rerun the rule.

36 No function requested
No valid recFunc Local variable was specified. For example, the
argument list begins with a comma. Define the recFunc parameter
and rerun the rule.

40 Key length equals zero for the MERGE function


This return code is issued by the MERGE and SUM functions only.
The KEYLEN parameter (for example, the total length of the key
fields for the WRITE function) is 0. Correct the KEYLEN parameter
and rerun the rule.

44 Open of SORTOUT file failed


Check the SORTOUT DD statement for the job. Correct the JCL and
rerun the rule.

623
Control-M/Analyzer User Guide

Code Description

48 Open of SRECOUT1 file failed


Check the SRECOUT1 DD statement for the job. Correct the JCL and
rerun the rule.

52 Open of SRECOUT2 file failed


Check the SRECOUT2 DD statement for the job. Correct the JCL and
rerun the rule.

56 SORTOUT file block size too small to run the MERGEX and SUMX
functions
The work buffer is not large enough. Increase the block size
(blkSize) of the SORTOUT file and rerun the rule. The block size can
be overridden only by the DCB parameter in the SORTOUT JCL
DD statement.

60 SORTOUT block size too small (block size must be sufficient for at
least three records)
SORTOUT block size is not large enough. Increase the block size
(blkSize) of the SORTOUT file and rerun the rule. The block size can
be overridden only by the DCB parameter in the SORTOUT JCL
DD statement.

64 The MERGEX and SUMX functions cannot be performed


Less than two files were specified for processing or the FILEID
parameter is identical for both files.
Specify two different input files and rerun the rule.

68 Number of arguments in list does not match the ARGNUM


parameter
Correct the ARGNUM parameter or the list of parameters passed
and rerun the rule.

over 100 Sort utility return codes


Detailed error messages are written to the SYSOUT output file.

624
8
8
Report Generation
This chapter includes the following topics:
 Report Types (on page 625)
 Rule Activity Report (on page 625)
 Dynamic Print Formatting Facility (on page 626)

Report Types
The following types of reports are available under Control-M/Analyzer:
 reports produced automatically by the operation of Control-M/Analyzer
 reports produced by scripts that utilize the IOA KeyStroke Language (KSL)
KSL scripts generate reports in batch mode that can be produced online with the Online facility. For
more information see the KeyStroke Language (KSL) User Guide.
 Control-M/Analyzer special reports that cannot readily be produced using the Online facility or KSL.
Some Control-M/Analyzer reports are produced from information in the Rule Activity file, Report file or
IOA Log file. Other reports are produced from the Active Balancing file, mission definition files, and the
Database.
The Reporting facility can be activated at any time.

Rule Activity Report


The Rule Activity report lists messages, system data, and DO PRINT statement output generated during a
Control-M/Analyzer invocation. The Rule Activity report is contained in the SYSPRINT member, which is
created automatically during the Control-M/Analyzer invocation.
This report can be viewed online through the Rule Activity Report Viewing screen. To view a Rule Activity
report, specify Option R for the appropriate rule in the Rule Activity display (screen BA). For more
information about this report, see Rule Activity Report Viewing Screen (on page 176). For more
information about the DO PRINT statement, see DO PRINT: Automated Balancing Statement (on page
405).
A typical Rule Activity report, as viewed in the Rule Activity Report Viewing screen, is illustrated in
Figure 372.

625
Control-M/Analyzer User Guide

Figure 372 Rule Activity Report Viewing Screen


----------- CONTROL-M/ANALZYER RULE ACTIVITY REPORT VIEWING -------------(BA.R)
COMMAND ===> SCROLL===> CRSR
-------------------------------------------------------------------------------
CTB001I- CONTROL-M/ANALYZER RUNTIME ENVIRONMENT STARTED - MODE IS STAND-ALONE - SCOPE
IS
CTB009I- GROUP-MODE IS "ACTIVE"
CTB00AI- INVOKED RULE=ARWARN01 RULE-LIB=CTB.PROD.RULES
*** CONTROL-M/ANALYZER SUMMARY OF INVOCATION REPORT ***

***---------------------------------------------------------------***
*** GROUP : INTRAC JOBNAME : M42INSGS /JOB13530 ***
*** MISSION : ARMISS01 RULE : ARWARN01 ***
*** CATEGORY: DAILY OWNER : M66 ***
*** RUN ON : 02/02/99 - 11:47 ***
***---------------------------------------------------------------***
CTB109I- Compilation started
CTB110I- Compilation completed successfully
CTB111I- Highest error code was 0
*
** ENTERING BLOCK: CHECK OF TYPE DATA
*
PRT: TIME IS NOT BETWEEN 12 P.M. AND 6 P.M.
PRT: YOU'RE OK FOR NOW, BUT DO NOT RELAX
==SHOUT : 'TIME IS NOT BETWEEN 12 P.M. AND 6 P.M --- RELAX ************' To: TS
PRESS END TO RETURN. LEFT AND RIGHT TO SEE MORE. 12.12.15

Dynamic Print Formatting Facility


The Dynamic Print Formatting facility formats numeric values and text strings according to user
specifications. This facility enables the user to produce reports (by the DO PRINT statement) in which
numbers and text are properly aligned (for example, by decimal point).
The Dynamic Print Formatting facility is invoked by specifying Y (Yes) in the F (Format) parameter to the
right of the DO PRINT statement in the Rule Definition screen. For more information about the DO PRINT
statement, see DO PRINT: Automated Balancing Statement (on page 405).

626
9
9
Rollback Facility
This chapter includes the following topics:
 Control-M/Analyzer Rollback Facility (on page 627)
 Activating the Rollback Facility (on page 628)
 Triggering the Rollback Facility through Control-M/Restart (on page 629)
 Viewing Deleted Variable Generations (on page 630)
 Displaying Rollback Results (on page 631)

Control-M/Analyzer Rollback Facility


The Control-M/Analyzer Rollback facility resets Control-M/Analyzer Database variables to values that are
set at an earlier point in time. The Rollback facility is used when unusual circumstances occur (for
example, a production error detected by Control-M/Analyzer) that require that applications and their
associated Control-M/Analyzer rules be rerun. To rerun these applications and their associated
Control-M/Analyzer rules, database variables may first have to be rolled back (reset) to their values prior
to the occurrence of the unusual circumstances. Rolling back values prevents subsequent invocations of
Control-M/Analyzer from accessing erroneous database values, and producing duplicate variable
generations for the same application.
Generally, Control-M/Analyzer Database variables are only written (committed) to the Database at rule
termination, after all calculations and checks have been performed. For this reason, variables can be set
and reset within a Control-M/Analyzer rule invocation many times. Until the changes are committed, the
Database is untouched and only the previous values of the Database variable are accessible by other
programs.
In some cases, the Control-M/Analyzer and application environments must be adjusted to their state prior
to an unsuccessful application run. This is achieved by deleting all variable generations committed during
the unsuccessful run.

627
Control-M/Analyzer User Guide

Activating the Rollback Facility


The Rollback facility is activated by the Rule Activity display (screen BA). Type the letter B in the option
field of screen BA and press Enter.
Figure 373 Rule Activity Display Screen
RULE ACTIVITY <D> GROUP * USERID JOBNAME
COMMAND ===> SCROLL===> CRSR
O JOBNAME JOBID STEPNAME DATE START ENDED RULE STATUS CODE
M01RUN 8263 08/08/00 17:04 17:04 RUNALL OK 0000
M32ADM 8266 08/08/00 17:05 17:05 ADMORDER OK 0000
M15SCH 8276 08/08/00 17:09 17:09 SCHEDULE OK 0000
M32ADM 8281 08/08/00 17:10 17:10 ADMORDER OK 0000
M32ADM 8284 08/08/00 17:13 17:13 ADMORDER OK 0000
B M43LBA 8289 08/08/00 17:14 17:20 ROLLBACK OK 0000
====== >>>>>>>>>>>>>>>> B O T T O M O F L I S T <<<<<<<<<<<<<< ======

OPTIONS: V VIEW L LOG R REPORT B ROLL BACK P PRINT 17.19.44

A confirmation window appears. To confirm the rollback, type Y and press Enter. To cancel the rollback,
type N and press Enter.
If the request is confirmed, variable generations committed by the selected rule invocation are deleted
(rolled back). Deleted variable generations continue to be displayed in the Online facility (Screens BA and
BV). However, these variable generations cannot be referred to or accessed by Control-M/Analyzer rules.

628
Control-M/Analyzer User Guide

Figure 374 Rollback Confirmation Screen


RULE ACTIVITY <D> GROUP * USERID JOBNAME
COMMAND ===> SCROLL===> CRSR
O JOBNAME JOBID STEPNAME DATE START ENDED RULE STATUS CODE
M01RUN 8263 08/08/00 17:04 17:04 RUNALL OK 0000
M32ADM 8266 08/08/00 17:05 17:05 ADMORDER OK 0000
M15SCH 8276 08/08/00 17:09 17:09 SCHEDULE OK 0000
M32ADM +------------------------+ 0 17:10 ADMORDER OK 0000
M32ADM | | 3 17:13 ADMORDER OK 0000
B M43LBA <--------| CONFIRM (Y/N) | 4 17:20 ROLLBACK OK 0000
====== >>>>> | | L I S T <<<<<<<<<<<<<< ======
+------------------------+

OPTIONS: V VIEW L LOG R REPORT B ROLL BACK P PRINT 17.19.44


After the rollback is completed, a message is displayed at the top of the screen.

After the rollback is completed, a message is displayed at the top of the screen.

Triggering the Rollback Facility through Control-M/Restart


The Control-M/Analyzer Rollback feature can be triggered by Control-M/Restart. When Control-M/Restart
resumes a job run by Control-M, the Rollback feature is automatically invoked if Control-M/Restart User
Exit CTRX001Q is installed. For information about using this interface (including a sample
Control-M/Analyzer rule), see the section of the INCONTROL for z/OS Administrator Guide dealing with
Control-M/Restart support for the Control-M/Analyzer Rollback Facility.

629
Control-M/Analyzer User Guide

Viewing Deleted Variable Generations


Variable generations deleted by the Rollback facility are marked by three asterisks (***) in the
GENERATION field in the Database Variable display.
To view variables deleted by the Rollback facility, type V (View) in the appropriate option field and press
Enter.
Figure 375 Database Variable Display
RULE ACTIVITY <D> GROUP * USERID JOBNAME
COMMAND ===> SCROLL===> CRSR
O JOBNAME JOBID STEPNAME DATE START ENDED RULE STATUS CODE
M01RUN 8263 08/08/00 17:04 17:04 RUNALL OK 0000
M32ADM 8266 08/08/00 17:05 17:05 ADMORDER OK 0000
M15SCH 8276 08/08/00 17:09 17:09 SCHEDULE OK 0000
M32ADM 8281 08/08/00 17:10 17:10 ADMORDER OK 0000
M32ADM 8284 08/08/00 17:13 17:13 ADMORDER OK 0000
V M43LBA 8289 08/08/00 17:14 17:20 ROLLBACK OK 0000
====== >>>>>>>>>>>>>>>> B O T T O M O F L I S T <<<<<<<<<<<<<< ======

OPTIONS: V VIEW L LOG R REPORT B ROLL BACK P PRINT 17.19.44

630
Control-M/Analyzer User Guide

The Database Variable display lists variable generations in creation date order, starting with the latest
generation. Rolled back generations are listed in their original position in the Database Variable display
with *** in the GENERATION field.
Figure 376 Rolled Back Generations in the Database Variable Display
--------<G>-------- GROUP INVENTORY VAR TOT* -------(BV.V)
COMMAND ===> SCROLL===> CRSR
O GROUP NAME --------- VARIABLE NAME ------ GENERATION ------------------------
INVENTRY TOT1 ***
Value : 90321
User Key : Run Id :
Creation Date : 08/08/00 17:19:39 By User : M43LBA Type : B
-------------------------------------------------------------------------------
INVENTRY TOT2 ***
Value : 90350

User Key : Run Id :


Creation Date : 08/08/00 17:18:09 By User : M43LBA Type : B
-------------------------------------------------------------------------------
INVENTRY TOT3 ***
Value : 90200
User Key : Run Id :
Creation Date : 08/08/00 17:14:54 By User : M43LBA Type : B
========>>>>>>>>>>>>>>>>>>>>>>>> END OF DATA <<<<<<<<<<<<<<<<<<<<<===========

OPTIONS: U UPDATE D DELETE 09.59.30

Displaying Rollback Results


Information about the rollback process applied to a specific variable generation is listed in the Database
Variable display screen when Option A (Additional Info) is specified in Display Type A (All Fields). For
more information on this topic see Display Type A (All Fields) (on page 151).

631
10
10
Control-M/Analyzer Interfaces
This chapter includes the following topics:
 Control-M/Analyzer Interfaces (on page 632)
 Interface to Control-M (on page 633)
• Using a DO CTBRULE statement (on page 633)
• Using the CTB STEP Parameter (on page 635)
 Control-M Job Definition Screen Format (on page 636)
 Interface to Control-D and Control-V (on page 637)
• Decollating Mission Definition Under Control-D and Control-V (on page 637)
 Interface to User Programs (on page 640)
• Passing Arguments to and from Control-M/Analyzer (on page 641)

Control-M/Analyzer Interfaces
This chapter provides information about Control-M/Analyzer interfaces to other INCONTROL products and
user products.
When other INCONTROL products are used with Control-M/Analyzer at your site, the IOA integrated
environment produces optimal results. Control-M/Analyzer can interface directly to Control-M and
Control-D to enhance their capabilities and improve the quality of the production process.
User programs developed by your site can also communicate with the IOA Environment through
Control-M/Analyzer. This interface gives new capabilities to your local site applications.
The results of Control-M/Analyzer rules that run under the Control-M or Control-D monitor are in the
Control-M or Control-D monitor SYSOUT respectively.
The following Control-M/Analyzer interfaces are documented in this chapter:
 interface to Control-M
 interface to Control-D
 interfaces to user programs
The Control-M/Analyzer interface to Control-M/Restart enables the CONTROLR procedure to trigger the
Control-M/Analyzer Rollback Facility. This interface is documented in Rollback Facility (on page 627).

632
Control-M/Analyzer User Guide

Interface to Control-M
The Control-M/Analyzer Runtime Environment can be invoked by specifying a DO CTBRULE statement or
the CTB STEP parameter in the Control-M Job Definition screen (only by users with Control-M and,
optionally, Control-M/Restart). These interfaces to Control-M/Analyzer enable balancing actions to be
performed on job sysouts and statistics. The name of the Control-M/Analyzer rules to be executed must
be specified. The called rule is read from the libraries referenced by the DABRULE DD statement.

Using a DO CTBRULE statement


When Control-M job results are analyzed, the specified Control-M/Analyzer rule is automatically executed
for each DO CTBRULE statement.
Note: If a DO CTBRULE statement is specified under ON PGMST ANYSTEP, the rule is executed only once
(meaning, the Control-M/Analyzer Runtime Environment is invoked one time only) and not once for each
step in the job.
Figure 377 Using DO CTBRULE in Control-M
JOB: GOVTREPT LIB CTM.PROD.SCHEDULE TABLE: PRODKPL
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
TIME: FROM UNTIL PRIORITY CONFIRM
============================================================================
OUT FINANCE-GOVTREPT-OK ODAT +
AUTO-ARCHIVE Y SYSDB Y MAXDAYS MAXRUNS
SYSOUT OP (C,D,F,N,R) FROM
RERUN - MAXRERUN RERUNMEM INTERVAL
STEP RANGE FR (PGM.PROC) TO
ON PGMST ANYSTEP PROCST CODES ***** A/O
DO CTBRULE = RULCTMM ARG
DO
ON PGMST PROCST CODES A/O
DO
SHOUT WHEN NOTOK TIME + DAYS TO TSO-M44 URGN R
MS JOB GOVTREPT ENDED "NOT OK"
SHOUT WHEN TIME + DAYS TO URGN
MS
======= >>>>>>>>>>>>>>>>>>> END OF SCHEDULING PARAMETERS <<<<<<<<<<<<<<<< =====

USE THE DOC COMMAND TO SHOW/HIDE JOB DOCUMENTATION 11.17.00

Note: Passing of arguments from DO CTBRULE statements to an invoked Control-M/Analyzer rule is not
yet supported.

633
Control-M/Analyzer User Guide

Corresponding Rule Definition Under Control-M/Analyzer


The SYSOUT System variable indicates the Control-M/Analyzer invocation method. When the
Control-M/Analyzer Runtime Environment is invoked by DO CTBRULE statement, the SYSOPT System
variable automatically contains the value CTMWORK. This variable can be specified as a criterion in the
rule definition to determine if an ON statement should be processed, as illustrated in Figure 378.
Figure 378 Control-M/Analyzer Display on Use of DO CTBRULE in Control-M
+-----------------------------------------------------------------------------+
OWNER M18 GROUP CTB_DEMO
UPDATED 08/08/00 - 12:32:00 BY M18
DESC SAMPLE RULE UNDER CONTROL-M
OPTIONS
===========================================================================
EXECUTE I UPON C
ON DATA
ALWAYS
DO SHOUT TO OPER URGENCY R
= CONTROL-M/ANALYZER STARTED UNDER CONTROL-M
DO SET = ERROR=0 C
===========================================================================
EXECUTE SYS UPON SYSOPT='CTMWORK' C
ON SYSDATA
MODE LINECT DATASTAMP
WHEN LINE 001 - 060 COL 001 - 080 STOP AND/OR
STRING = INVALID DATA IN TAPE:
DO SET = ERROR=ERROR+1 C
DO EXTRACT = TAPE
LEVEL 0 LINE +000 COL +023 - +028 PROCESS TYP
DO PRINT = INVALID DATA FOUND IN TAPE : %%TAPE F C
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE E UPON C
ON DATA
IF ERROR EQ 0 C
DO COND = RUN-PROD ODAT +
DO TERMINAT = OK COD 0000
DO
ELSE
DO SHOUT TO OPER URGENCY R
= CONTROL-M/ANALYZER TERMINATES UNDER CONTROL-M
DO SHOUT TO OPER URGENCY R
= (%%ERRORS) FOUND
DO TERMINAT = NOTOK COD 0999
DO
(ENTER "ALWAYS", "IF")
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====
PLEASE FILL IN RULE DEFINITION. 16.01.34

The group name can be specified in the GROUP parameter of one of the following:
 a Control-M/Analyzer rule
 a Control-M scheduling definition
If a group name is specified in both of these GROUP parameters, the rule is implemented with the group
name specified in the Control-M scheduling definition.

634
Control-M/Analyzer User Guide

The ON SYSDATA Data Selection parameter can be specified within the Control-M/Analyzer rule definition
to indicate processing of SYSDATA. SYSDATA is an IOA term that designates the data in the following job
sysout datasets:
 the job log (console messages)
 the expanded JCL
 the system output messages
SYSDATA is created by the AutoArchive facility provided by Control-M/Restart.
Control-M/Analyzer rules can add or delete prerequisite conditions. Control-M (and all other INCONTROL
products) can test for the existence of these conditions and react accordingly. Control-M/Analyzer rules
can also read, examine, and change AutoEdit symbol members, that can affect the submission of other
jobs.
Note: Control-M arguments passed to a Control-M/Analyzer rule are accessed by the rule using the
RARGnn System variable, where nn is the 2-digit number that indicates the position of the argument in
the argument list. For more information see Passing Arguments While Invoking Control-M/Analyzer (on
page 42).

Using the CTB STEP Parameter


Control-M/Analyzer steps can be added at the beginning or end of a job stream when invoking
Control-M/Analyzer under Control-M. The CTB STEP parameter adds the steps of a Control-M/Analyzer
rule or mission at the beginning or end of a Control-M job.
Note: Control-M arguments passed to a Control-M/Analyzer rule are accessed by the rule using the
RARGnn System variable, where nn is the 2-digit number that indicates the position of the argument in
the argument list. For more information see Passing Arguments While Invoking Control-M/Analyzer (on
page 42).

635
Control-M/Analyzer User Guide

Control-M Job Definition Screen Format


Figure 379 Control-M Job Definition Screen Format

Subparameters
The CTB STEP parameter contains the subparameters described in Table 299
Table 299 CTB STEP Subparameters

Subparameter Description

AT Indicates where to place the Control-M/Analyzer step in the job.


Mandatory. Valid values are:
 START – The Control-M/Analyzer step is the first step of the job.
 END – The Control-M/Analyzer step is the last step of the job.

NAME Name of the Control-M/Analyzer entity. Must be a valid name for a


Control-M/Analyzer rule or mission. Mandatory.

TYPE Type of Control-M/Analyzer entity. Mandatory. Valid values are:


 RULE – Entity is a Control-M/Analyzer rule.
 MISSION – Entity is a Control-M/Analyzer mission.

ARGUMENTS Arguments to be passed as parameters to the Control-M/Analyzer


step. Optional.

Note: The 60-character ARGUMENTS line is displayed only after the CTB STEP line is filled in and Enter is
pressed.

636
Control-M/Analyzer User Guide

General Information
A maximum of two CTB STEP statements (such as, one START statement and one END statement) can be
specified. Upon filling in the first CTB STEP line on the screen and pressing Enter, the ARGUMENTS line
and the second CTB STEP line are displayed. If the second CTB STEP line is filled in and Enter is pressed,
its ARGUMENTS line is displayed.
Arguments are automatically passed to the Control-M/Analyzer step as a PARM=‘arguments’ parameter in
the JCL of the step.
The name of the Control-M/Analyzer procedure that is used in the CTB STEP statement is obtained from
the CTBPROC Control-M/Analyzer installation parameter.
The names of the Control-M/Analyzer steps in the job submitted by Control-M are determined by source
parameters in the CTBPARM member. The CTMSTSTA parameter specifies the name of the first step
added. The CTMSTEND parameter specifies the name of the last step added. Control-M reads the step
names specified in these parameters and uses them as the Control-M/Analyzer step names in the
submitted job.

Interface to Control-D and Control-V


Decollating Mission Definition Under Control-D and Control-V
Control-D and Control-V can each invoke the Control-M/Analyzer Runtime Environment by specifying the
command DO CTBRULE in the applicable Decollating Definition screen.
This interface to Control-D or Control-V enables balancing actions to be performed on outputs decollated
by Control-D or Control-V. The name of the Control-M/Analyzer rule to be executed is specified. When
Control-D or Control-V decollation is performed, the specified Control-M/Analyzer rule is automatically
executed.
Figure 380 Automatic Execution of Control-M/Analyzer Rule in Control-D
--------- CONTROL-D CATEGORY DAILY JOB DAYTASK ----------(R.S)
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
SHOUT WHEN NOTOK TIME + DAYS TO OPER2 URG R
MSG ==== REPORT DECOLLATION FOR REPORT1 ENDED N O T O K ====
SHOUT WHEN TIME + DAYS TO URG
MSG
===========================================================================
DEF COPIES 01 LVL USER UNIDENT DEST MAX COPIES
===========================================================================
ON CLASS = D EXTWTR DEST FORM
PRT COPIES LVL USER DEST MAX COPIES
PRINT/CDAM PARMS =
WHEN LINE 003 - 003 COL 034 - 050 PRINT REF NEXT PAGE CONTID AND/OR
STRING = INVENTORY REPORT
DO USER = WAREHOUSE LVL LINE COL - S N T
DO USER = PRODUCTION LVL LINE COL - S N T
SYNONYM = CONCAT =
DO NAME = INVENTORY REPORT LINE COL -
DO PRINT = STD MUST - F C
DO BACKUP = BKP0007D
DO CTBRULE = RULPAGM ARG
DO
USE THE SCHED COMMAND TO SHOW/HIDE SCHEDULING PARAMETERS 11.33.28

637
Control-M/Analyzer User Guide

Note: Passing of arguments from DO CTBRULE statements to an invoked Control-M/Analyzer rule is not
yet supported.

Corresponding Rule Definition Under Control-M/Analyzer


The rule specified in a DO CTBRULE statement is invoked by Control-D or Control-V
 once before decollation begins
 once for each page that meets the Control-D or Control-V WHEN criteria (that are specified directly
above statement DO CTBRULE in the decollating mission definition)
 once after decollation ends
Note: When working with datasets without ASA codes, changing the Control-D ALLOCOPT parameter
value affects whether a printing control character is inserted before column 1 in the decollated output. If
ON PAGE is specified in a Control-M/Analyzer rule definition that is invoked by a DO CTBRULE statement
in a Control-D or Control-V decollating mission, the Control-M/Analyzer WHEN and EXTRACT statements
may receive files from Control-D or Control-V before the printing control character is added to the record.
To ensure that a report decollated by Control-D or Control-V is received by Control-M/Analyzer in the
same format regardless of how Control-M/Analyzer is invoked, the ALLOCOPT parameter in Control-D or
Control-V should not be specified. If the ALLOCOPT parameter is specified, this may require the
Control-M/Analyzer WHEN and DO EXTRACT column ranges to be shifted when Control-M/Analyzer is
invoked by a DO CTBRULE statement.
The SYSOPT System variable indicates the Control-M/Analyzer invocation method. When the
Control-M/Analyzer Runtime Environment is invoked by Control-D or Control-V, the SYSOPT System
variable automatically contains one of the values described in Table 300.
Table 300 SYSOPT Values when Control-D Invokes Control-M/Analyzer

Value Description

CTDFIRST First invocation of Control-D or Control-V (such as, before


(or CTVFIRST) decollation begins).

CTDWORK Invocation of Control-D or Control-V for each page received by


(or CTVWORK) Control-M/Analyzer.

CTDLAST Last invocation of Control-D or Control-V (such as, after decollation


(or CTVLAST) ends).

As illustrated on the following page, the SYSOPT System variable can be specified as criteria in the rule
definition to determine if an ON block should be processed. Initialization is usually performed during the
first Control-D or Control-V invocation of Control-M/Analyzer (such as, SYSOPT=CTDFIRST or CTVFIRST).
Each time a Control-D or Control-V page is passed to Control-M/Analyzer (such as, SYSOPT=CTDWORK or
CTVWORK), balancing operations are performed. After the last Control-D or Control-V page is received
(such as, SYSOPT=CTDLAST or CTVLAST), a DO TERMINAT statement is usually specified to determine
the balancing result.

638
Control-M/Analyzer User Guide

The group name can be specified in the GROUP parameter of


 a Control-M/Analyzer rule
 a Control-D or Control-V decollating mission
If a group name is specified in both of these parameters, the rule is implemented with the group name
specified in the Control-D or Control-V decollating mission.
Figure 381 Use of the GROUP Parameter
LIBRARY : CTB.PROD.RULES RULE : RULPAGM
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M18 GROUP CTB_DEMO
UPDATED 08/08/00 - 12:23:00 BY M18
DESC SAMPLE RULE UNDER CONTROL-D
OPTIONS
===========================================================================
EXECUTE I UPON SYSOPT EQ 'CTDFIRST' C
ON DATA
ALWAYS
DO SHOUT TO OPER URGENCY R
= CONTROL-M/ANALYZER STARTED UNDER CONTROL-D
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE PAG UPON SYSOPT EQ 'CTDWORK' C
ON PAGE
MODE PG LINECT DATASTAMP
WHEN LINE 001 - 060 COL 001 - 080 STOP AND/OR
STRING = .AL.
DO EXTRACT = VAR
LEVEL 0 LINE +000 COL 0001 - 0080 PROCESS TYP SU
DO
WHEN LINE - COL - STOP AND/OR
STRING =
DO
===========================================================================
EXECUTE E UPON SYSOPT EQ 'CTDLAST' C
ON DATA
ALWAYS
DO SET = DB_LAST_TOTAL=VAR C
DO SHOUT TO OPER URGENCY R
= CONTROL-M/ANALYZER TERMINATES UNDER CONTROL-D
DO
IF VAR GT DB_LAST_TOTAL@G0 C
DO REMARK = TOTAL IS REASONABLE
DO TERMINAT = OK COD 0000
DO
ELSE
DO REMARK = TOTAL IS UNREASONABLE
DO TERMINAT = NOTOK COD 0999
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====
FILL IN RULE DEFINITION. 15.31.54

If DO TERMINAT is specified earlier than the CTDLAST (or CTVLAST) invocation, subsequent
Control-M/Analyzer invocations are not performed.

639
Control-M/Analyzer User Guide

The ON PAGE Data Selection parameter can be specified within the Control-M/Analyzer rule definition to
indicate processing of Control-D or Control-V pages. Each Control-D or Control-V page that meets the
Control-D or Control-V WHEN criteria is passed to Control-M/Analyzer for processing.
When a Control-M/Analyzer rule (invoked by Control-D or Control-V) terminates by a DO
TERMINAT=NOTOK statement, it is as if the DO NOTOK Control-D or Control-V command was issued. DO
NOTOK causes the decollating mission to terminate NOTOK.
Control-M/Analyzer can pass information back to Control-D or Control-V as follows. When a DO REMARK
Control-M/Analyzer statement is specified by a rule that was invoked by Control-D or Control-V, the first
20 characters of the remark are returned to Control-D or Control-V (as if the DO REMARK command was
issued in the decollating mission definition). This remark is displayed in certain Control-D and Control-V
User Report List formats.
Control-M/Analyzer rules can add or delete prerequisite conditions. Control-D and Control-V (and all other
INCONTROL products) can test for the existence of these conditions and react accordingly.

Interface to User Programs


The Control-M/Analyzer Runtime environment can be invoked by a call from a user program. This User
Program interface provides standardization of all balancing activities and checks.
For example, at a specific site, it is not efficient for each programmer to write validity checks inside each
program (PL/1, COBOL, and so on). It is preferable that all programmers call one Control-M/Analyzer
routine that invokes a rule. Instead of inserting balancing checks into programs, all balancing checks at
the site are provided externally to the user programs. The balancing checks are performed using one
facility, and can be controlled efficiently from one Control-M/Analyzer screen.
User programs can pass arguments to Control-M/Analyzer. The Control-M/Analyzer rule can modify these
values, and pass them back as arguments to the calling user program.
After rule termination
any changes made to values during rule execution are returned to the calling program
For more information, see Passing Arguments to and from Control-M/Analyzer (on page 641).
 Register 15 contains the rule termination code
The IOA.SAMPLE library contains the CALLCTBA member, a sample assembler program, and the
CALLCTBC member, a sample "C" program, that illustrate how to call Control-M/Analyzer rules from user
programs.

640
Control-M/Analyzer User Guide

Passing Arguments to and from Control-M/Analyzer


The arguments described in Table 301 are passed to the Control-M/Analyzer rule.
Table 301 Arguments Passed to the Control-M/Analyzer Rule

Argument Description

Rule name 8-character rule name.

Mission name 8-character mission name.

Group name 20-character group name.

Result Result or Termination status of the called rule (returned by


Control-M/Analyzer). This argument is 4 bytes (1 fullword) in length.
The result contains one of the following numeric values:
 1–OK status
 2–NOTOK status
 3–TOLER status

Number of User Number of user arguments sent to the rule. This argument is 4
Arguments bytes (1 fullword) in length.

User Arguments A maximum of 50 user arguments may be specified. Each argument


has 101 characters and as is formatted as follows:
 Byte 1 –The length of the user argument (from 1 to 100
characters).
 Bytes 2-101–The value of the user argument.

The user argument format is illustrated in Figure 382.


Figure 382 User Argument Format

User arguments can be referenced by the rule through the RARGxx System variable. For example,
RARG01 corresponds to the first user Argument, RARG02 corresponds to the second user argument, and
so on
After rule termination, changes made to RARGxx System variable values during rule execution are
returned to the calling program (the user program that invoked the rule).

641
Control-M/Analyzer User Guide

Corresponding Rule Definition under Control-M/Analyzer


The SYSOPT System variable indicates the Control-M/Analyzer invocation method. When the
Control-M/Analyzer Runtime Environment is invoked by a user program call, the SYSOPT System variable
automatically contains the value CTBUSER. This variable can be specified as criteria in the rule definition
to determine if an ON block should be processed.
RARGnn System variables contain the values of arguments passed from the calling program. These
arguments can be used by the rule, stored in the Database, manipulated, and so on, as illustrated in
Figure 383.
Figure 383 Arguments Stored as System Variables
LIBRARY : CTB.PROD.RULES RULE : CTBUPRG
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
OWNER M66 GROUP GENERAL
UPDATED 08/08/00 - 15:53:39 BY M66
DESC STORE VALUES PASSED FROM A USER PROGRAM IN THE DATABASE.
OPTIONS
===========================================================================
EXECUTE STORE UPON SYSOPT='CTBUSER' C
ON DATA
ALWAYS
/* ARGUMENT 1 IS GROUP NAME
/* ARGUMENT 2 IS VARIABLE NAME
/* ARGUMENT 3 IS VARIABLE VALUE
DO SET = DB_%%RARG01.%%RARG02='%%RARG03' C
DO TERMINAT = OK COD 0000
DO
(ENTER "ALWAYS", "IF")
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====
PLEASE FILL IN RULE DEFINITION. 16.01.34

642
11
11
Solveware Samples Kit
This chapter includes the following topics:
 General (on page 643)
 SolveWare Samples (on page 644)
 Implementation Steps (on page 644)
• Step 1 – Study the Samples Kit documentation (on page 644)
• Step 2 – Customize the rules before implementation (on page 644)
• Step 3 – Test and implement the rules (on page 644)
 Sample Rules (on page 645)
• Solveware Rule Documentation (on page 645)
• Rule Logic (on page 648)

General
The SolveWare Samples kit contains sample Control-M/Analyzer rules that help you implement
Control-M/Analyzer quickly and successfully at your site. These sample rules are based on rules created
by our customers when they implemented Control-M/Analyzer. We have generalized them and included
those rules that provide
 rule writing tips and techniques to help you begin using Control-M/Analyzer
 ideas on where to start the implementation, by illustrating case studies (top down balancing within an
application, cross-application balancing, and so on) implemented by our customers
 additional examples illustrating how to utilize Control-M/Analyzer features (for example, the
Reconciliation facility)
The SolveWare Samples kit is composed of the following components:
 Documentation
Printed documentation for the SolveWare Samples kit is provided in this chapter. This documentation
typically includes a General Description, Rule Logic, Technical Highlights, and Recommendations and
Implementation Tips for each sample rule in the kit.
 Libraries
The Control-M/Analyzer installation tape includes the following three libraries:
• SOLVRULE—Sample Control-M/Analyzer rules
• IOA SAMPREPS—Sample reports (members named CTB...) used by the rules
• SOLVJCL—Sample jobs to invoke the rules
Refer to these libraries to understand the documentation in this chapter.

643
Control-M/Analyzer User Guide

SolveWare Samples
This chapter contains SolveWare relating to the following topics:
 Rules 1A and 1B—Balancing Grand Totals
 Rules 2A and 2B—Verifying Totals for Columns of Numbers
 Rule 3 — Checking Each Line in a Report (With DO BLOCK Statements)
 Rule 4 —Producing Formatted Reports (With the Dynamic Print Facility)
 Rule 5—Producing Summary Records for Large Files (With Reconciliation Functions SETKEY and SUM)
 Rule 6—Comparing Two Large Files (With Reconciliation Functions WRITE and MERGEX)

Implementation Steps
The steps involved in adopting, modifying and implementing the SolveWare samples are described below.

Step 1 – Study the Samples Kit documentation


Examine the documentation and rule descriptions provided in this chapter. Compare them with the actual
rules and reports provided in the SolveWare libraries. Determine whether the subject or concept is
relevant to your site.

Step 2 – Customize the rules before implementation


The rules provided in this kit are samples of concepts and ideas that could be implemented at your site.
They must be tailored to your specific environment. We have provided hypothetical report structures, file
record layouts, and so on. Some customization is necessary when implementing these rules at your site.
For example, the column range of relevant information must be changed appropriately.
Implementation tips and recommendations are included in the rule documentation.

Step 3 – Test and implement the rules


All SolveWare rules should be fully tested before they are implemented and put into production. The three
Control-M/Analyzer rule implementation modes enable you to verify automated quality control procedures
before using them.
 Define mode
Control-M/Analyzer ignores the rule during processing. No actions are performed and the rule
terminates with a rule status of OK.
 Simulate mode
The rule is processed and resulting output (for example, detailed reports describing problems) are
produced. However, no actions are taken and the Control-M/Analyzer Database is not modified. This
mode enables you to test rules without impacting the production environment.

644
Control-M/Analyzer User Guide

 Active mode
This is the production mode for Control-M/Analyzer rules. Data is evaluated and all actions defined by
the user are performed.

Sample Rules
SolveWare sample rules are documented on the following pages. When reviewing this documentation,
refer to the appropriate rule in the SOLVRULE library, the specified input report in the IOA SAMPREPS
library, and the corresponding JCL in the SOLVJCL library.

Solveware Rule Documentation


Figure 384 Solveware Rule Documentation

Rule Name: Balancing Grand Totals

Rule Member: BRULE1A, BRULE1B

Report Member: CTBREP8 JCL Members: BJCL1A, BJCL1B

General Description
The following rules illustrate solutions to the following common requirement: to determine that report
totals are reasonable and consistent both internally and externally (such as, with information in other
reports). A sample inventory report, part of which is shown below, is used to demonstrate how this
requirement is satisfied.

645
Control-M/Analyzer User Guide

Figure 385 Sample Inventory Report (1)


INVENTORY REPORT
================
WAREHOUSE NO: 1001 DEPARTMENT: 100 – FINAL ASSEMBLY SHOP
==== ===========================
SHELF QNTY QNTY QNTY QNTY IN TOTAL PART
ITEM NO. DESCRIPTION LIFE UNIT AVAIL ORDER PROCESS QNTY CLASS
=========== ============== ===== ==== ====== ===== ======= ======= ===========
1233-781-21 RIVET D. 0.1 ACR NONE KG 100.00 250.00 350.00 FLOOR STOCK
1233-781-25 RIVET D. 0.5 ACR NONE KG 500.00 500.00 1000.00 FLOOR STOCK
1233-781-27 RIVET D. 0.7 ACR NONE KG 100.00 100.00 200.00 FLOOR STOCK
2201-800-01 METAL O RING 0.1 NONE EA 34.00 34.00 FLOOR STOCK
2201-800-22 METAL O RING 2.2 NONE EA 20.00 30.00 50.00 FLOOR STOCK
2201-800-27 METAL O RING 2.7 NONE EA 35.00 35.00 FLOOR STOCK
2274-711-21 WASHER D. 0.1 NONE KG 10.50 10.50 21.00 FLOOR STOCK
2274-711-25 WASHER D. 0.5 NONE KG 450.00 400.00 850.00 FLOOR STOCK
2274-711-27 WASHER D. 0.7 NONE KG 100.00 100.00 FLOOR STOCK
2274-811-21 BOLT 1/8 NONE KG 50.00 25.00 75.00 FLOOR STOCK
=================================================================================
TOTALS: 2114.50 1475.50 3590.00

The rules extract one or more totals from a report and verify that the extracted quantities are reasonable.
They demonstrate how to take various actions if everything is OK and how to take other actions (for
example, print error messages to a user report, use the Shout facility to send messages to a TSO user ID,
and terminate a job with a status of NOTOK) if something is wrong.
Rule 1A extracts one total from a report and verifies that it is reasonable, which in this simple example
means over 1,000. Rule 1B extracts several totals and verifies that they are mutually consistent. The logic
of each rule is explained in more detail in Rule 1A Logic (on page 646) and Rule 1B Logic (on page 646)
below.

Rule 1A Logic
 In the first block, read the report from the file, identify the grand totals line, and extract the total at
the bottom of the TOTAL QNTY column.
 In the second block, verify that the extracted number is larger than 1000. If it is, perform the
following actions:
• Print the extracted quantity to the balancing report.
• Terminate the rule OK with a condition code of 0.
If it is not, perform the following actions:
• Print an error message to the balancing report
• Shout a message to a TSO userid
• Terminate the rule NOTOK with a condition code of 555

Rule 1B Logic
 In the first block, read the report file, analyze the report to identify the grand totals line, and extract
grand totals for the QNTY AVAIL, QNTY ORDER and TOTAL QNTY columns into the variables QNTY1,
QNTY2 and QNTY3, respectively.
 In the second block, verify that QNTY1 + QNTY2 = QNTY3. If it does not, perform the actions listed
in Rule 1A.

646
Control-M/Analyzer User Guide

Technical Highlights
 The ON FILE statement identifies the file or library and member that contains the report to be
analyzed.
 The library containing the rule is referenced in the BJCL1A or BJCL1B member by the DABRULE
DD statement.
 The WHEN LINE/COL statement detects "TOTALS:" (a typical string for this type of balancing), the DO
EXTRACT statement obtains the totals from the same line (+0) that satisfied the WHEN statement.
 SYSJOBNAME and SYSDATE System variables are used in Rule 1B DO SHOUT and DO PRINT
statements to refer to the current job name and date.

Recommendations and Implementation Tips


 Use Page mode (PG) when extracting data from a multipage report.
 Even if a rule ends with the status OK, use an explicit DO PRINT statement to display a message such
as "Everything OK".
 When a rule ends, always use DO TERMINAT statements to explicitly terminate with OK, TOLER or
NOTOK status.
 The GROUP specified in the rule should be defined in the Control-M/Analyzer Database prior to rule
invocation.
Figure 386 Rule 1B Logic

Rule Name: Verifying Totals for Columns of Numbers

Rule Member: BRULE2A, BRULE2B

Report Member: CTBREP9 JCL Members BJCL22A, BJCL2B

General Description
The following rules illustrate the automation of another common task: Determine that the sum of the
numbers listed in a vertical column of a report equals the total for that column printed in the report. A
slightly modified copy (Figure 387) of the inventory report used for Rule 1A is used to demonstrate how
this task is accomplished.

647
Control-M/Analyzer User Guide

Figure 387 Sample Inventory Report (2)


INVENTORY REPORT
================

WAREHOUSE NO: 1001 DEPARTMENT: 100 – FINAL ASSEMBLY SHOP


==== ===========================

SHELF QNTY QNTY QNTY QNTY IN TOTAL PART


ITEM NO. DESCRIPTION LIFE UNIT AVAIL ORDER PROCESS QNTY CLASS
=========== ================ ===== ==== ======= ===== ======= ======= ===========
1233-781-21 RIVET D. 0.1 ACR NONE KG 1,100.00 250.00 350.00 FLOOR STOCK
1233-781-25 RIVET D. 0.5 ACR NONE KG 1,500.00 500.00 1000.00 FLOOR STOCK
1233-781-27 RIVET D. 0.7 ACR NONE KG 2,100.00 100.00 200.00 FLOOR STOCK
2201-800-01 METAL O RING 0.1 NONE EA 34.00 34.00 FLOOR STOCK
2201-800-22 METAL O RING 2.2 NONE EA 20.00 30.00 50.00 FLOOR STOCK
2201-800-27 METAL O RING 2.7 NONE EA 35.00 35.00 FLOOR STOCK
2274-711-21 WASHER D. 0.1 NONE KG 10.50 10.50 21.00 FLOOR STOCK
2274-711-25 WASHER D. 0.5 NONE KG 450.00 400.00 850.00 FLOOR STOCK
2274-711-27 WASHER D. 0.7 NONE KG 100.00 100.00 FLOOR STOCK
2274-811-21 BOLT 1/8 NONE KG 50.00 25.00 75.00 FLOOR STOCK
=================================================================================
TOTALS: 2,114.50 1475.50 3590.00

Each rule contains two independent WHEN statements. The first WHEN statement uses the presence of
unique punctuation (a hyphen in column 6) to identify detail lines. Each "detail" line lists information
about a specific item in the warehouse. It is identified by a catalog number on the left side of the line.
Every catalog number has the same structure (XXXX-XXX-XX). Therefore, every detail line has a hyphen in
column 6.
The DO EXTRACT statement automatically sums the extracted quantities when parameter TYPE is set to
SU (sum). The DO EXTRACT statement uses the BFNUM process to convert formatted numbers (for
example, with commas) for mathematical comparisons.
The second WHEN statement identifies a total line and extracts totals from that line (+0). This process is
very similar to that of Rule 1.
If the calculated sum of the numbers extracted from the column does not equal the total for that column
contained in the report, appropriate notification is sent to specified locations using the Shout facility.

Rule Logic
The INPUT block reads a report in page mode from the sysout file referenced by the SYSUT2
DD statement. This block contains two independent WHEN statements. The first one looks for detail lines
and sums the appropriate column entries. The second one looks for the total line and extracts the
appropriate column totals.

648
Control-M/Analyzer User Guide

Table 302 SolveWare Rule Logic (1)

Rule Description

First WHEN statement: When column 6 contains a hyphen, sum the


quantity extracted from the QNTY AVAIL field in
Local variable QTYA. Rule 2B does the same for
more than one column.

Second WHEN statement: When TOTALS: is found in columns 1 to 20, extract


the total quantity in columns 50 to 60. Store the
extracted total in the QTYB Local variable. Rule 2B
does the same for more than one total value.

The CHECK block compares QTYA and QTYB.

If QTYA does not equal QTYB:  Print the calculated and extracted totals in the
balancing report.
 Use the Shout facility to announce that the job
identified in the SYSJOBNAME System variable is
not balanced.
 Terminate with NOTOK rule status and a
condition code of 555.

If QTYA does equal QTYB:  Print an IN BALANCE message containing the


SYSDATE and SYSJOBNAME in the balancing
report.
 Terminate with OK rule status and a condition
code of 0.

Technical Highlights
 The ON SYSOUT statement indicates that the sysout file referenced by the SYSUT2 DD statement is
the input file to be balanced.
 The JCL for this rule uses the IEBGENER utility to produce the sysout file that is identified using the
ON SYSOUT statement. However, the same sysout file could have been generated by any user
application program or some other utility. For more detailed information about utilities, see the
INCONTROL for z/OS Utilities Guide.

649
Control-M/Analyzer User Guide

Recommendations and Implementation Tips


 Searching for special symbols is a technique used to identify detail entries and the total entry. In this
rule, a catalog number with a hyphen had to appear in every detail entry. Other useful symbols
include a decimal point in a numeric field that cannot be blank and a slash in a date.
 The DD statement (SYSUT2 in this rule) identified by the ON SYSOUT statement must include the
FREE=CLOSE parameter. In addition, the sysout class must be a held class. If these two requirements
are not satisfied, Control-M/Analyzer cannot read the sysout file.
 Use Page mode (PG) when extracting data from a multi-page report.
Figure 388 Solveware Rule Logic (2)

Rule Name: Checking Each Line in a Report (with DO BLOCK Statements)

Rule Member: BRULE3

Report Member: CTBREP10 JCL Member: BJCL3

General Description
This rule illustrates how to perform a number of checks on every line of a report. This is implemented
using the Control-M/Analyzer DO BLOCK statement.
The employee personnel report shown below is used with this rule. On each employee line, the rule
performs three checks:
 Is the salary greater than or equal to 90,000?
 Are sick days greater than or equal to 14?
 Are vacation days greater than 31?
For each line with an error, the employee details are printed with an appropriate error message.

650
Control-M/Analyzer User Guide

Figure 389 Sample Employee Personnel Report


E M P L O Y E E S R E P O R T ----- FOR MANAGEMENT DEPARTMENT DATE: 08/08/00
EMPLOYEE EMPLOYEE OFFICE ANNUAL SOCIAL NO. OF JOB CLASS UNION INSURANCE SICK VAC
NO. NAME NO. SAL SECURITY NO.DEPENDENTS CODE DUES DAYS DAYS
======== ======== ====== ====== ============ ========== ========= ====== ========= === ====
64263 A. HERMAN 01 97,000 XXX-YY-ZZZZ 4 212.00 372.00 04 14
64535 V. GOLD 06 57,000 XXX-YY-ZZZZ 2 106.00 252.00 01 05
65173 S. PATTEL 14 86,500 XXX-YY-ZZZZ 2 234.00 390.00 02 09
65225 D. HAMILTON 08 67,500 XXX-YY-ZZZZ 2 156.00 222.00 01 07
65229 J. NEWMAN 19 46,500 XXX-YY-ZZZZ 5 133.00 399.00 00 07
65253 T. MASUIE 14 39,500 XXX-YY-ZZZZ 3 214.00 181.00 01 07
65474 S. SMITH 16 64,500 XXX-YY-ZZZZ 6 044.00 056.00 00 06
65551 J. WAYNE 06 55,000 XXX-YY-ZZZZ 6 151.00 222.00 03 07
65571 J. TAYLOR 11 29,000 XXX-YY-ZZZZ 2 156.00 220.00 01 07
65653 R. JOHNSON 14 26,000 XXX-YY-ZZZZ 3 119.00 256.00 04 07
65763 R. BURKE 07 30,500 XXX-YY-ZZZZ 2 098.00 301.00 01 06
65774 R. ONYON 08 27,500 XXX-YY-ZZZZ 2 156.00 222.00 01 07
65838 G. LEVY 04 29,500 XXX-YY-ZZZZ 2 065.00 118.00 02 07
65965 J. WEISSMAN 04 37,500 XXX-YY-ZZZZ 4 151.00 222.00 05 00

Technical Highlights
 At the end of the INPUT block, the DO BLOCK statement calls the CHECK block to determine if each
extracted value is reasonable.
 The error counter, the ERROR Local variable, is incremented every time an error is encountered in the
CHECK block.
 The END block is executed one time after all detail lines have been examined.

651
Control-M/Analyzer User Guide

Rule Logic
The rule structure above is illustrated in Table 303.
Table 303 Solveware Rule Structure

EXECUTE INPUT

ON SYSOUT...

WHEN

DO EXTRACT EMP_NUM

DO EXTRACT SICK

DO BLOCK CHECK

EXECUTE END

ON DATA

IF ERROR >0

DO PRINT OUT-OF BAL

DO TERMINATE NOTOK

ELSE

DO TERMINATE OK

EXECUTE CHECK

ON DATA

IF SICK > 14

DO PRINT...

652
Control-M/Analyzer User Guide

In the INPUT block:


Read a report in Page mode (PG) from a file referenced by the SYSUT2 DD statement.
When column 48 is a hyphen, extract the employee details (number, name, and office number) and
the specific fields to be checked (annual salary, sick days, vacation days).
Call the CHECK block to determine if the extracted quantities are reasonable. The CHECK block is
written at the end of the rule but is executed now because it is called by DO BLOCK.
 After all detail lines have been checked, execute the END block.
If the error counter is more than zero:
• Print an error message
• Use the Shout facility to notify user TSO-M55 that the report is not balanced
• Terminate with rule status NOTOK and a condition code of 999
If the error counter is zero:
• Notify user TSO-M55 that the report is balanced
• Terminate with rule status OK and condition code 0
Note: It is important to terminate this block explicitly in case of OK and NOTOK to prevent calling the
CHECK block one time too many.
 In the CHECK block, verify that the extracted values of the current employee are valid:
• Annual salary greater than or equal to 90,000?
• Sick days less than or equal to 14?
• Vacation days less than or equal to 31?
If a problem is found, print a message and increment the error counter.
Note: The CHECK block appears at the end of the rule but is executed now for each employee line
because it is called by the DO BLOCK statement.

653
Control-M/Analyzer User Guide

Recommendations and Implementation Tips


 Lines to be checked are identified by a hyphen in column 48. The hyphen is part of the social security
number that must exist for each employee.
 The JCL for Rule 3 is essentially identical to the JCL for Rule 2.
 The DD statement (SYSUT2 in this rule) identified by the ON SYSOUT statement must include the
FREE=CLOSE parameter. In addition, the sysout class must be a held class. If these two requirements
are not satisfied, Control-M/Analyzer cannot read the sysout file.
Figure 390 Solveware Rule Logic (3)

Rule Name: Producing Formatted Reports (with the Dynamic Print Facility)

Rule Member: BRULE4

Report Member: CTBREP10 JCL Member: BJCL4

General Description
This rule demonstrates how the Control-M/Analyzer Dynamic Print facility can be used to produce
formatted output reports.
This rule extracts records for all employees whose annual salary is over 40,000 and prints them in a table
using various formatting options. The report consists of the following fields:
 Social Security number (printed as is)
 Salary (with thousand delimiter and 2 digits after the decimal point)
 Insurance (with no thousand delimiter and 2 digits after the decimal point)
 Union dues (with the minus sign to the right of the number)
 Vacation days (right justified in a field with a length of 6 bytes)
The input report is identical to the report used by Rule 3:

654
Control-M/Analyzer User Guide

Figure 391 Sample Input Report


E M P L O Y E E S R E P O R T ----- FOR MANAGEMENT DEPARTMENT DATE: 08/08/09
EMPLOYEE EMPLOYEE OFFICE ANNUAL SOCIAL NO. OF JOB CLASS UNION INSURANCE SICK VAC
NO. NAME NO. SAL SECURITY NO.DEPENDENTS CODE DUES DAYS DAYS
======== ======== ====== ====== ============ ========== ========= ====== ========= ==== ====
64263 A. HERMAN 01 97,000 XXX-YY-ZZZZ 4 212.00 372.00 04 14
64535 V. GOLD 06 57,000 XXX-YY-ZZZZ 2 106.00 252.00 01 05
65173 S. PATTEL 14 86,500 XXX-YY-ZZZZ 2 234.00 390.00 02 09
65225 D. HAMILTON 08 67,500 XXX-YY-ZZZZ 2 156.00 222.00 01 07
65229 J. NEWMAN 19 46,500 XXX-YY-ZZZZ 5 133.00 399.00 00 07
65253 T. MASUIE 14 39,500 XXX-YY-ZZZZ 3 214.00 181.00 01 07
65474 S. SMITH 16 64,500 XXX-YY-ZZZZ 6 044.00 056.00 00 06
65551 J. WAYNE 06 55,000 XXX-YY-ZZZZ 6 151.00 222.00 03 07
65571 J. TAYLOR 11 29,000 XXX-YY-ZZZZ 2 156.00 220.00 01 07
65653 R. JOHNSON 14 26,000 XXX-YY-ZZZZ 3 119.00 256.00 04 07
65763 R. BURKE 07 30,500 XXX-YY-ZZZZ 2 098.00 301.00 01 06
65774 R. ONYON 08 27,500 XXX-YY-ZZZZ 2 156.00 222.00 01 07
65838 G. LEVY 04 29,500 XXX-YY-ZZZZ 2 065.00 118.00 02 07
65965 J. WEISSMAN 04 37,500 XXX-YY-ZZZZ 4 151.00 222.00 05 00

Rule Logic
 The INIT block prints the report header.
 For every employee whose annual salary is over 40,000, the PROC block
• extracts 5 data elements: social security number, annual salary, insurance, union dues, and
vacation days
• formats and prints the extracted values as required
 The END block always terminates the rule with OK status and a condition code of 0.

Technical Highlights
 The input file is identified in the ON FILE statement and read in DS (dataset) mode.
 The Dynamic Print facility is invoked as part of the DO PRINT command to format all four variables
that need to be formatted.
Typical formats for popular numeric fields are illustrated.
Figure 392 Solveware Rule Logic (4)

Rule Name: Producing Summary Statistics for Large Files (with Reconciliation Functions
SETKEY and SUM)
Rule Member: BRULE5

Report Member: CTBREP11 JCL Member BJCL5

655
Control-M/Analyzer User Guide

General Description
This rule produces subtotals by record attributes. The input file for this rule contains an record type
attribute field (car type) in columns 19-23 and a transaction amount to be totaled (in packed decimal
format) in columns 35-41. The rule produces transaction amount subtotals by car type.
This rule shows how to use the SETKEY and SUM functions of the Reconciliation facility. The summary
results are written to the file referenced by the SORTOUT DD statement, then formatted and printed in
the Rule Activity report.

Rule Logic
 In the SETKEY block
Define the car type as a 5-character key beginning in column 19.
Use statement DO CALLUSER to invoke the SETKEY function of the Reconciliation facility and define
car type as the key.
Print the system user code to the Rule Activity report.
 In block SUM:
Specify the transaction amount as the field to be summed. This field is a 7 character packed decimal
field beginning in column 35.
Use statement DO CALLUSER to invoke the SUM function of the Reconciliation facility to perform the
summation.
Print the system user code to the Rule Activity report.
 The Reconciliation function results are printed in block PRINT:
Scan all records in the file referenced by DD statement SORTOUT. This file contains the summary
records written as output of the SUM function in the previous block.
For each summary record:
• Extract the car type from columns 19-23.
• Extract and convert (from packed decimal) the transaction amount.
• Print both fields.
 The END block always terminates the rule with status OK and a condition code of zero.

656
Control-M/Analyzer User Guide

Technical Highlights
 The record key is defined in the "SETKEY" block. The SETKEY function requires two parameters
(offset and length) for each segment of the key. In this case, the key has only one segment: the 5
columns starting in column 19.
 Each field to be totaled is defined in the "SUM" block. The SUM function requires three parameters
(offset, length, field type) for each field being totaled. In this example, only one field is being totaled:
a packed decimal value in the seven columns starting in column 35.
 The BUNPK process converts numbers (without decimals) and the BUNPKn process converts numbers
(with n decimals) from packed format to standard decimal character format. The DO SET following
this DO EXTRACT eliminates any leading zeros resulting from this conversion.

Recommendations and Implementation Tips


 The JCL for this rule can be used as a model for similar Reconciliation rules using functions SETKEY
and SUM.
 The input file is referenced by the SORTIN DD statement. The output file is referenced by SORTOUT
DD statement. The SORTWKnn DD statements are used by the SUM function as work files to sort the
input file by its record key.
 The SYSURC System variable (system user code) indicates the results of invoking the CTBRECL
program. A zero value indicates successful completion. Therefore, BMC recommends that you print
this variable in order to indicate any problems.
Figure 393 Solveware Rule Logic (5)

Rule Name: Comparing Two Large Files (with Reconciliation Functions WRITE and MERGEX)

Rule Member: BRULE6

Report Members: CTBREP7A, CTBREP7B JCL Member BJCL6

657
Control-M/Analyzer User Guide

General Description
This rule demonstrates how the Reconciliation facility can compare two files whose keys can be matched
and produce a list of discrepancies. Both input files for this rule contain information about customer
checks, for example, check numbers and check amounts, but the record formats of the files are not the
same.
This rule uses the WRITE and MERGEX Reconciliation facility functions to detect non-matching records in
two dissimilar check files. Matching is based on check number. The resulting report provides check
number, check amount, and a field (file indicator) that indicates in which file the unmatched check
appears.

Rule Logic
 In the PREPARE block, set up Local variables required for the WRITE function.
 In the WRITE1 and WRITE2 blocks
• specify the input file
• specify the lines to be searched (.AL. indicates all lines)
Use DO EXTRACT statements to extract the check number and check amount (from their respective
locations in the two files).
Use the DO CALLUSER statement to invoke the WRITE function.
 In block MERGEX
Use DO CALLUSER statement to invoke the MERGEX function that compares the two files prepared in
the two previous blocks.
 The RESULT block prints unmatched records found by the MERGEX function:
Scan all records in the file referenced by the SRECOUT1 DD statement. This file contains all of the
unmatched records found by the MERGEX Reconciliation function.
For each unmatched record:
• Extract the check number.
• Extract the check amount.
• Extract the file indicator (1 or 2) that provides information about the type of problem.
• Print all of the extracted fields.
 Block END always terminates the rule with status OK and a condition code of zero.

Technical Highlights
Each of the two input files is referenced in a separate block by its own ON FILE statement. The input files
do not have identical formats. Each file's record key and additional fields are defined in each invocation of
the WRITE function.

658
Control-M/Analyzer User Guide

Recommendations and Implementation Tips


 The JCL for this rule can be used as a model for similar Reconciliation rules using the WRITE and
MERGEX functions.
 To produce a separate output file containing all records that do match, add the SRECOUT2
DD statement to the JCL and change the value of the MATCH parameter from NO to YES.
WRITE function output (MERGEX function input) records are in the file referenced by the SORTIN
DD statement. The SORTWKnn DD statements are used by the MERGEX function to sort the two WRITE
function outputs. The sorted output, in the file referenced by the SORTOUT DD statement, becomes the
input to the comparison stage of the MERGEX function. The MERGEX function output file of unmatched
records is referenced by the SRECOUT1 DD statement.

659
12
12
A Editing Rule Definitions in the IOA Edit
Environment
Rule Definition parameters can be edited (moved, copied, deleted, repeated) by performing line editing
commands, similar to standard ISPF line commands, from within the IOA Edit environment.
The Edit environment in a Rule Definition screen is accessed by typing EDIT in the COMMAND field and
pressing Enter.
Figure 394 Edit Environment in The Rule Definition Screen
LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+--------------------------------------------------------------------------+
__ OWNER M43 GROUP ACCT_INV
__ UPDATED 08/08/00 - 15:25:54 BY M43
__ DESC REORDER INVENTORY ITEM CHR001 IF NECESSARY
__ OPTIONS
__ ======================================================================
__ /* INITIALIZATION OF THE MINIMUM AMOUNT REQUIRED ON-HAND FOR
__ /* INVENTORY ITEM CHR001.
__ EXECUTE SETUP UPON C
__ ON DATA
__ ALWAYS
__ DO SET = MIN_CHR001=100 C
__ DO
__ (ENTER "ALWAYS", "IF")
__ =========================================================================
__ /* DETERMINE CURRENT ON-HAND QUANTITY OF INVENTORY ITEM CHR001 BY
__ /* EXTRACTING THIS VALUE FROM SYSOUT DDNAME INVENTRY.
__ EXECUTE CHECK UPON C
__ ON SYSOUT PROCST PGMST DDNAME INVENTRY JOBNM
__ MODE PG LINECT 0060 DATASTAMP
__ WHEN LINE 001 - 060 COL 010 - 020 TYPE STOP AND/OR
PLEASE FILL IN RULE DEFINITION. 08.50.43

A 2-character line editing command field, marked by underscores, is displayed for each line on the screen.
Editing commands are typed directly onto these underscores.
Incorrectly specified line editing commands can be corrected by typing over them correctly. Line editing
commands can be deleted by blanking them out or by specifying the RESET command in the COMMAND
field.
Specified line editing commands are processed when Enter is pressed.
Control-M/Analyzer performs automatic syntax checking to ensure that the rule definition is still
syntactically correct after editing. If an edit will invalidate the rule definition, a message is displayed at the
top of the screen and the edit is not performed. For guidelines and recommendations for editing rule
definitions, see Maintaining Valid Rule Definitions (on page 664).
All operations available in the Rule Definition screen can be performed while in the Edit environment (for
example, parameter values may be changed, the Rule Definition screen may be saved, and the screen
exited).

660
Control-M/Analyzer User Guide

To exit the Edit environment, retype EDIT in the COMMAND field and press Enter. Line editing command
fields are removed from the display.

Line Editing Command Subjects


Line editing commands can be performed on the following:
Table 304 Subjects of Line Editing Commands

Unit Description and Commands

Single Lines One single line on the screen.


Examples:
 Continuation line.
 Single line DO statements (such as DO COND).

Logical Lines All parameter lines for a specific parameter, including its
subparameters and continuation lines.
Examples:
 WHEN, whose subparameters span several lines.
 EXECUTE, whose continuation lines span several lines.

Logical Blocks Functional group of parameter lines. Rule definitions consist of at


least one logical block – an EXECUTE block – that in turn consists of
sub-blocks (such as WHEN, ALWAYS, and IF).
Examples:
 EXECUTE block, its sub-blocks, and their respective parameter
lines.
 IF sub-block and its respective parameter lines.

Multiple Lines User-specified group of parameter lines.


Example:
Series of DO statements.

Separator Lines A line of equal signs that separates EXECUTE blocks on the Rule
Definition screen. Separator lines are not processed during rule
execution.

661
Control-M/Analyzer User Guide

Line Editing Commands


The following tables describe the types of line editing commands that exist in the Edit environment.
Table 305 Line Editing: Delete Commands

Command Effect

DS Delete a single line.

DL Delete a logical line.

DB Delete a logical block or sub-block.

DD Delete lines between two DD specifications.

D Delete a line. Control-M/Analyzer determines whether to delete a


single or logical line based on line type.

Table 306 Line Editing: Copy Commands

Command Effect

CS Copy a single line.

CL Copy a logical line.

CB Copy a logical block or sub-block.

CC Copy lines between two CC specifications.

C Copy a line. Control-M/Analyzer determines whether to copy a single


or logical line based on line type.

Copy commands are used in conjunction with Location commands. The lines and blocks are
placed at the position indicated by Location command A or B (described below).

662
Control-M/Analyzer User Guide

Table 307 Line Editing: Move Commands

Command Effect

MS Move a single line.

ML Move a logical line.

MB Move a logical block or sub-block.

MM Move lines between two MM specifications.

M Move a line. Control-M/Analyzer determines whether to move a


single or logical line based on line type.

Move commands are used in conjunction with Location commands. The lines and blocks are
placed at the position indicated by Location command A or B (described below).

Table 308 Line Editing: Repeat Commands

Command Effect

RS Repeat a single line.

RL Repeat a logical line.

RB Repeat a logical block or sub-block.

RR Repeat lines between two RR specifications.

R Repeat a line. Control-M/Analyzer determines whether to repeat a


single or logical line based on line type.

The repeated lines and blocks are placed immediately after the lines and blocks marked
with the command.

Table 309 Line Editing: Insert Command

Command Effect

I Inserts a new logical line or block after the logical line or block
marked with an I.

663
Control-M/Analyzer User Guide

Table 310 Line Editing: Location Commands

Command Effect

Indication of the position where lines and blocks should be placed.

A (After) Indicates that lines or blocks should be placed after the line marked
with an A.

B (Before) Indicates that lines or blocks should be placed before the line
marked with a B.

Location commands A and B are used in conjunction with Copy (C, CS, CL, CC, CB) and
Move (M, MS, ML, MM, MB) commands.

Maintaining Valid Rule Definitions


Since rule definitions must be syntactically correct at all times, you should consider the following issues
when specifying line editing commands:
 The result of a line editing command is dependent on the line on which the command is specified. For
example, the D command deletes either a single or a logical line based on the line type.
 Logical lines function as a unit and cannot be separated. For example, when a logical command is
specified within a logical line, such as a subparameter line or a continuation line, the specified
operation is performed on the entire logical line.
 Block commands should be specified on the main lines of the block. For example, to delete an
EXECUTE block, the DB command should be specified on the EXECUTE line. To delete an IF
sub-block, the DB command should be specified on either the LABEL or the IF line.
A separator line must exist between EXECUTE blocks. Therefore, when editing multiple lines that
represent entire logical blocks, separator lines (===) should be included in the line selection. In this
case, BMC recommends the use of logical block commands. Logical block commands automatically
include separator lines in the editing operation.
 Blank parameter lines are added automatically by Control-M/Analyzer (to enable you to specify
additional parameters) and cannot be deleted.
 BMC recommends that, wherever possible, you use the D, C, M, and R commands for editing (instead
of DS, DL, CS, CL, MS, ML, RS, and RL), because these commands automatically retain the logical
structure of the rule definition.

664
Control-M/Analyzer User Guide

Examples
Example 1
Insert additional DO statements within a DO block using command I (Insert).
Figure 395 Example 1 - Using Insert Command - Before
LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+--------------------------------------------------------------------------+
__ ===========================================================================
__ /* COMPARE THE CURRENT ON-HAND AMOUNT (DATA BASE VARIABLE
__ /* CURR_ONHAND) TO THE MINIMUM REQUIRED AMOUNT (DATA BASE VARIABLE
__ /* MIN_CHR001). DETERMINE IF REORDERING IS NECESSARY, AND PRINT A
__ /* MESSAGE INDICATING THE RESULTS
__ EXECUTE COMPARE UPON C
__ ON DATA
__ ALWAYS
I DO SET = DIFFER=CURR_ONHAND-MIN_CHR001 C
__ DO
__ IF CURR_ONHAND>=MIN_CHR001 C
__ DO PRINT = DO NOT REORDER; SURPLUS=%%DIFFER F C
__ DO
__ ELSE
__ DO PRINT = REORDER; DEFICIT=%%DIFFER F C
__ DO
__ (ENTER "ALWAYS", "IF")
__ ===========================================================================
__ EXECUTE UPON C
__ ON
PLEASE FILL IN RULE DEFINITION. 08.53.27

An additional DO statement line has been opened.


Figure 396 Example 1 - Using Insert Command - After
LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+--------------------------------------------------------------------------+
__ ===========================================================================
__ /* COMPARE THE CURRENT ON-HAND AMOUNT (DATA BASE VARIABLE
__ /* CURR_ONHAND) TO THE MINIMUM REQUIRED AMOUNT (DATA BASE VARIABLE
__ /* MIN_CHR001). DETERMINE IF REORDERING IS NECESSARY, AND PRINT A
__ /* MESSAGE INDICATING THE RESULTS
__ EXECUTE COMPARE UPON C
__ ON DATA
__ ALWAYS
__ DO SET = DIFFER=CURR_ONHAND-MIN_CHR001 C
__ DO C
__ DO
__ IF CURR_ONHAND>=MIN_CHR001 C
__ DO PRINT = DO NOT REORDER; SURPLUS=%%DIFFER F C
__ DO
__ ELSE
__ DO PRINT = REORDER; DEFICIT=%%DIFFER F C
__ DO
__ (ENTER "ALWAYS", "IF")
__ ===========================================================================
__ EXECUTE UPON C
PLEASE FILL IN RULE DEFINITION. 08.53.27

665
Control-M/Analyzer User Guide

Example 2
Delete an EXECUTE block. Use of the DB (Delete Block) command is the preferred method. The DB
command removes all parameters, comments, continuation lines, and separator lines of the specified
block. DB must be specified on a main line of the block (such as, EXECUTE or ON). In this example, the
SETUP EXECUTE block (indicated by A) is deleted.
Figure 397 Example 2 - Using Delete Command - Before
LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+--------------------------------------------------------------------------+
__ OWNER M43 GROUP ACCT_INV
__ UPDATED 08/08/00 - 15:25:54 BY M43
__ DESC REORDER INVENTORY ITEM CHR001 IF NECESSARY
__ OPTIONS
__ ===========================================================================
__ /* INITIALIZATION OF THE MINIMUM AMOUNT REQUIRED ON-HAND FOR
__ /* INVENTORY ITEM CHR001.
DB EXECUTE SETUP UPON C
__ ON DATA
__ ALWAYS
__ DO SET = MIN_CHR001=100 C
__ ===========================================================================
__ /* DETERMINE CURRENT ON-HAND QUANTITY OF INVENTORY ITEM CHR001 BY
__ /* EXTRACTING THIS VALUE FROM SYSOUT DDNAME INVENTRY.
__ EXECUTE CHECK UPON C
__ ON SYSOUT PROCST PGMST DDNAME INVENTRY JOBNM
__ MODE PG LINECT 0060 DATASTAMP
__ WHEN LINE 001 - 060 COL 010 - 020 TYPE STOP AND/OR
__ STRING = CHR001
__ DO EXTRACT = CURR_ONHAND
PLEASE FILL IN RULE DEFINITION. 08.59.42

The SETUP EXECUTE block has been deleted. EXECUTE block CHECK has scrolled upwards on the Rule
Definition screen.
Figure 398 Example 2 - Using Delete Command - After
LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+--------------------------------------------------------------------------+
__ OWNER M43 GROUP ACCT_INV
__ UPDATED 08/08/00 - 15:25:54 BY M43
__ DESC REORDER INVENTORY ITEM CHR001 IF NECESSARY
__ OPTIONS
__ ===========================================================================
__ /* DETERMINE CURRENT ON-HAND QUANTITY OF INVENTORY ITEM CHR001 BY
__ /* EXTRACTING THIS VALUE FROM SYSOUT DDNAME INVENTRY.
__ EXECUTE CHECK UPON C
__ ON SYSOUT PROCST PGMST DDNAME INVENTRY JOBNM
__ MODE PG LINECT 0060 DATASTAMP
__ WHEN LINE 001 - 060 COL 010 - 020 TYPE STOP AND/OR
__ STRING = CHR001
__ DO EXTRACT = CURR_ONHAND
__ LEVEL 0 LINE +000 COL +050 - +060 PROCESS TYP
__ DO
__ WHEN LINE - COL - TYPE STOP AND/OR
__ STRING =
__ DO
__ ===========================================================================
__ /* COMPARE THE CURRENT ON-HAND AMOUNT (DATA BASE VARIABLE
PLEASE FILL IN RULE DEFINITION. 09.00.12

666
Control-M/Analyzer User Guide

Example 3
Move multiple DO statements from one sub-block to another. The MM (Multiple Move) command is
specified at the beginning and the end of the DO statements that are moved. The B (Before) command
specifies the location before which these lines are placed.
Figure 399 Example 3 - Using Move Command - Before
LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+--------------------------------------------------------------------------+
__ /* COMPARE THE CURRENT ON-HAND AMOUNT (DATABASE VARIABLE
__ /* CURR_ONHAND) TO THE MINIMUM REQUIRED AMOUNT (DATABASE VARIABLE
__ /* MIN_CHR001). DETERMINE IF REORDERING IS NECESSARY, AND PRINT A
__ /* MESSAGE INDICATING THE RESULTS
__ EXECUTE COMPARE UPON C
__ ON DATA
__ ALWAYS
MM DO SET = DIFFER=CURR_ONHAND-MIN_CHR001 C
MM DO SET = REASON=TOLER(CURR_ONHAND,MIN_CHR001,10) C
__ DO
__ IF CURR_ONHAND>=MIN_CHR001 C
B_ DO PRINT = DO NOT REORDER; SURPLUS=%%DIFFER F C
__ DO
__ ELSE
__ DO PRINT = REORDER; DEFICIT=%%DIFFER F C
__ DO
__ (ENTER "ALWAYS", "IF")
__ ===========================================================================
__ EXECUTE UPON C
__ ON
PLEASE FILL IN RULE DEFINITION. 09.02.21

The two DO SET statements have been moved to the specified location.
Figure 400 Example 3 - Using Move Command - After
LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
__ /* COMPARE THE CURRENT ON-HAND AMOUNT (DATABASE VARIABLE
__ /* CURR_ONHAND) TO THE MINIMUM REQUIRED AMOUNT (DATABASE VARIABLE
__ /* MIN_CHR001). DETERMINE IF REORDERING IS NECESSARY, AND PRINT A
__ /* MESSAGE INDICATING THE RESULTS
__ EXECUTE COMPARE UPON C
__ ON DATA
__ ALWAYS
__ DO
__ IF CURR_ONHAND>=MIN_CHR001 C
__ DO SET = DIFFER=CURR_ONHAND-MIN_CHR001 C
__ DO SET = REASON=TOLER(CURR_ONHAND,MIN_CHR001,10) C
__ DO PRINT = DO NOT REORDER; SURPLUS=%%DIFFER F C
__ DO
__ ELSE
__ DO PRINT = REORDER; DEFICIT=%%DIFFER F C
__ DO
__ (ENTER "ALWAYS", "IF")
__ ===========================================================================
__ EXECUTE UPON C
__ ON
PLEASE FILL IN RULE DEFINITION. 09.03.16

Now, the ALWAYS sub-block should be deleted. The DB (Delete Block) command is used to remove this
sub-block from the definition.

667
Control-M/Analyzer User Guide

Figure 401 Example 3 - Deleting Sub-Block – Before


LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
__ /* COMPARE THE CURRENT ON-HAND AMOUNT (DATA BASEVARIABLE
__ /* CURR_ONHAND) TO THE MINIMUM REQUIRED AMOUNT (DATABASE VARIABLE
__ /* MIN_CHR001). DETERMINE IF REORDERING IS NECESSARY, AND PRINT A
__ /* MESSAGE INDICATING THE RESULTS
__ EXECUTE COMPARE UPON C
__ ON DATA
DB ALWAYS
__ DO
__ IF CURR_ONHAND>=MIN_CHR001 C
__ DO SET = DIFFER=CURR_ONHAND-MIN_CHR001 C
__ DO SET = REASON=TOLER(CURR_ONHAND,MIN_CHR001,10) C
__ DO PRINT = DO NOT REORDER; SURPLUS=%%DIFFER F C
__ DO
__ ELSE
__ DO PRINT = REORDER; DEFICIT=%%DIFFER F C
__ DO
__ (ENTER "ALWAYS", "IF")
__ ===========================================================================
__ EXECUTE UPON C
__ ON
PLEASE FILL IN RULE DEFINITION. 09.03.16

The ALWAYS sub-block has been deleted. The IF sub-block has scrolled upwards on the Rule Definition
screen.
Figure 402 Example 3 - After Deleting Sub-Block – After
LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
__ /* COMPARE THE CURRENT ON-HAND AMOUNT (DATABASE VARIABLE
__ /* CURR_ONHAND) TO THE MINIMUM REQUIRED AMOUNT (DATABASE VARIABLE
__ /* MIN_CHR001). DETERMINE IF REORDERING IS NECESSARY, AND PRINT A
__ /* MESSAGE INDICATING THE RESULTS
__ EXECUTE COMPARE UPON C
__ ON DATA
__ IF CURR_ONHAND>=MIN_CHR001 C
__ DO SET = DIFFER=CURR_ONHAND-MIN_CHR001 C
__ DO SET = REASON=TOLER(CURR_ONHAND,MIN_CHR001,10) C
__ DO PRINT = DO NOT REORDER; SURPLUS=%%DIFFER F C
__ DO
__ ELSE
__ DO PRINT = REORDER; DEFICIT=%%DIFFER F C
__ DO
__ (ENTER "ALWAYS", "IF")
__ ===========================================================================
__ EXECUTE UPON C
__ ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 09.04.23

If CURR_ONHAND is less than MIN_CHR001, the DO statements specified after parameter ELSE are
processed. The DO after the ELSE refers to variable %%DIFFER, but %%DIFFER has not been set
appropriately. Copy the appropriate DO statements from IF to ELSE using the CC and B commands.

668
Control-M/Analyzer User Guide

Figure 403 Example 3 - Copying DO Statements – Before


LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
__ /* COMPARE THE CURRENT ON-HAND AMOUNT (DATABASE VARIABLE
__ /* CURR_ONHAND) TO THE MINIMUM REQUIRED AMOUNT (DATABASE VARIABLE
__ /* MIN_CHR001). DETERMINE IF REORDERING IS NECESSARY, AND PRINT A
__ /* MESSAGE INDICATING THE RESULTS
__ EXECUTE COMPARE UPON C
__ ON DATA
__ IF CURR_ONHAND>=MIN_CHR001 C
CC DO SET = DIFFER=CURR_ONHAND-MIN_CHR001 C
CC DO SET = REASON=TOLER(CURR_ONHAND,MIN_CHR001,10) C
__ DO PRINT = DO NOT REORDER; SURPLUS=%%DIFFER F C
__ DO
__ ELSE
B_ DO PRINT = REORDER; DEFICIT=%%DIFFER F C
__ DO
__ (ENTER "ALWAYS", "IF")
__ ===========================================================================
__ EXECUTE UPON C
__ ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 09.04.23

The two specified lines have been copied.


Figure 404 Example 3 - After Copying DO Statements – After
LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
__ /* COMPARE THE CURRENT ON-HAND AMOUNT (DATABASE VARIABLE
__ /* CURR_ONHAND) TO THE MINIMUM REQUIRED AMOUNT (DATABASE VARIABLE
__ /* MIN_CHR001). DETERMINE IF REORDERING IS NECESSARY, AND PRINT A
__ /* MESSAGE INDICATING THE RESULTS
__ EXECUTE COMPARE UPON C
__ ON DATA
__ IF CURR_ONHAND>=MIN_CHR001 C
__ DO SET = DIFFER=CURR_ONHAND-MIN_CHR001 C
__ DO SET = REASON=TOLER(CURR_ONHAND,MIN_CHR001,10) C
__ DO PRINT = DO NOT REORDER; SURPLUS=%%DIFFER F C
__ DO
__ ELSE
__ DO SET = DIFFER=CURR_ONHAND-MIN_CHR001 C
__ DO SET = REASON=TOLER(CURR_ONHAND,MIN_CHR001,10) C
__ DO PRINT = REORDER; DEFICIT=%%DIFFER F C
__ DO
__ (ENTER "ALWAYS", "IF")
__ ===========================================================================
__ EXECUTE UPON C
__ ON
PLEASE FILL IN RULE DEFINITION. 09.05.52

669
Control-M/Analyzer User Guide

Example 4
Copy a WHEN statement and some of its DO statements to another EXECUTE block. The CC (Multiple
Copy) command is specified at the beginning and the end of the parameters that are copied. The B
(Before) command specifies the location before which these lines are placed.
Figure 405 Example 4 - Using Copy Command - Before
LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
__ ===========================================================================
__ /* DETERMINE CURRENT ON-HAND QUANTITY OF INVENTORY ITEM CHR001 BY
__ /* EXTRACTING THIS VALUE FROM SYSOUT DDNAME INVENTRY.
__ EXECUTE CHECK UPON C
__ ON SYSOUT PROCST PGMST DDNAME INVENTRY JOBNM
__ MODE PG LINECT 0060 DATASTAMP
CC WHEN LINE 001 - 060 COL 010 - 020 TYPE STOP AND/OR
__ STRING = CHR001
__ DO EXTRACT = CURR_ONHAND
CC LEVEL 0 LINE +000 COL +050 - +060 PROCESS TYP
__ DO COMMIT = NOW VAR CURR_ONHAND C
__ DO
__ WHEN LINE - COL - TYPE STOP AND/OR
__ STRING =
__ DO
===========================================================================
.
.
.
.
.
.
__ ===========================================================================
__ EXECUTE CHECK2 UPON C
__ ON SYSOUT PROCST PGMST DDNAME INVENTRY JOBNM
__ MODE PG LINECT 0060 DATASTAMP
B_ WHEN LINE - COL - TYPE STOP AND/OR
__ STRING =
__ DO
===========================================================================
__ EXECUTE UPON C
__ ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

The specified WHEN statement and DO statements have been successfully copied.

670
Control-M/Analyzer User Guide

Figure 406 Example 4 - Using Copy Command - After


LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
.
.
.
.
.
.
.
.
===========================================================================
__ EXECUTE CHECK2 UPON C
__ ON SYSOUT PROCST PGMST DDNAME INVENTRY JOBNM
__ MODE PG LINECT 0060 DATASTAMP
__ WHEN LINE 001 - 060 COL 010 - 020 TYPE STOP AND/OR
__ STRING = CHR001
__ DO EXTRACT = CURR_ONHAND
__ LEVEL 0 LINE +000 COL +050 - +060 PROCESS TYP
__ DO
__ WHEN LINE - COL - TYPE STOP AND/OR
__ STRING =
__ DO
_ ===========================================================================
__ EXECUTE UPON C
__ ON
======= >>>>>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 09.21.56

Example 5
Insert a continuation line between existing continuation lines. BMC recommends that command R
(Repeat) be used to repeat the previous logical line.
Figure 407 Example 5 - Using Insert Command - Before
LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
_ ===========================================================================
__ /* COMPARE THE CURRENT ON-HAND AMOUNT (DATABASE VARIABLE
__ /* CURR_ONHAND) TO THE MINIMUM REQUIRED AMOUNT (DATABASE VARIABLE
__ /* MIN_CHR001). DETERMINE IF REORDERING IS NECESSARY, AND PRINT A
__ /* MESSAGE INDICATING THE RESULTS
__ EXECUTE COMPARE UPON C
__ ON DATA
__ ALWAYS
__ DO SET = DIFFER=CURR_ONHAND-MIN_CHR001 C
__ DO
__ IF CURR_ONHAND>=MIN_CHR001 C
__ DO PRINT = DO NOT REORDER F C Y
R SURPLUS=%%DIFFER C Y
__ NO AUTHORIZATION FOR REORDER C
__ DO
__ ELSE
__ DO PRINT = REORDER; DEFICIT=%%DIFFER F C
__ DO
__ (ENTER "ALWAYS", "IF")
===========================================================================
PLEASE FILL IN RULE DEFINITION. 09.24.39

671
Control-M/Analyzer User Guide

The continuation line has been repeated. The repeated line can be modified as necessary.
Figure 408 Example 5 - Using Copy Command - After
LIBRARY : CTB.PROD.RULES RULE : REORDER
COMMAND ===> SCROLL===> CRSR
+-----------------------------------------------------------------------------+
__ ===========================================================================
__ /* COMPARE THE CURRENT ON-HAND AMOUNT (DATABASE VARIABLE
__ /* CURR_ONHAND) TO THE MINIMUM REQUIRED AMOUNT (DATABASE VARIABLE
__ /* MIN_CHR001). DETERMINE IF REORDERING IS NECESSARY, AND PRINT A
__ /* MESSAGE INDICATING THE RESULTS
__ EXECUTE COMPARE UPON C
__ ON DATA
__ ALWAYS
__ DO SET = DIFFER=CURR_ONHAND-MIN_CHR001 C
__ DO
__ IF CURR_ONHAND>=MIN_CHR001 C
__ DO PRINT = DO NOT REORDER F C Y
__ SURPLUS=%%DIFFER C Y
__ SURPLUS=%%DIFFER C Y
__ NO AUTHORIZATION FOR REORDER C
__ DO
__ ELSE
__ DO PRINT = REORDER; DEFICIT=%%DIFFER F C
__ DO
__ (ENTER "ALWAYS", "IF")
PLEASE FILL IN RULE DEFINITION. 09.26.02

672
13
13
B Reserved Words
Control-M/Analyzer reserves certain words for its own use. These words are listed in the table in this
appendix. They should not be specified when naming rules, missions, variables, and so on. This
prohibition applies to all Control-M/Analyzer function names and system variable names.
An additional restriction prohibits user-designated variable names and expressions that begin with the
letters SYS. Control-M/Analyzer reserves all names that begin with SYS for system variables.
If it is necessary to specify these words as names, surround the reserved word with apostrophes. For
more information, see Expression Delimiters (on page 510).
Control-M/Analyzer reserved words are listed below. Words marked with an asterisk have been reserved
by Control-M/Analyzer for future use.
Table 311 Control-M/Analyzer Reserved Words

ABEND BXuvwxyz FCOL OK SHOUT

ADD BY FILE ON STOP

ADDSYM BZONED FLINE ON_CLASS SOURCE1

ALL CALLUSER FORM ON_COMPARE SOURCE2

ALWAYS CDAM FROMVALUE* ON_DATA SU

AND CLASS GETMEM ON_DB2 SUBSTFROM

ARG COMMIT GOTO ON_DDNAME SUBSTTO

AV COND GROUP ON_DSN SYSDATA

BBINC CREATED HEADER ON_FILE SYSOUT

BBINF DATA IF ON_PAGE TCOL

BBINH DATASTAMP INCLUDE ON_SPECIAL* TERMINATE

BCPROCn DATE LABEL ON_SYSDATA TIME

BFLTB DB2 LEVEL ON_SYSOUT TLINE

BFNUM DD LIBSYM ON_VSAM TOLER

BFNUME DDNAME LINE OPTIONS TOVALUE*

BLOCK DELETE LINECT OR TRACEOPT*

673
Control-M/Analyzer User Guide

BPADZ DESC LOOP* OWNER TYPE

BTLOWER DEST MEMLIB PAGE UPDATED

BTRIMB DO MEMSYM PARM UPON

BTRIML DSN MODE PROCESS URGENCY

BTRIMR ELSE MSG PUTMEM USER_CODE

BTUPPER EVAL NAME REMARK USERBLOCK

BUILTIN EXCLUDE NONE RESULT USERRC

BUNPK EXECUTE NOTOK RULE VAR

BUNPKn EXIT NOW RUNID* VSAM

BUPROC EXTRACT NOWDEL SEARCH WHEN

BWn EXTWTR ODATE SET WHILE*

674
14
14
C Calling Control-M/Analyzer User Routines
User routines can be written to supplement the functions of Control-M/Analyzer. When user routines are
called (by a DO CALLUSER statement), these routines typically receive variables from Control-M/Analyzer
as arguments. For more information, see DO CALLUSER: Automated Balancing Statement (on page 371).
These variables can be modified by the user routine and then passed back to the Control-M/Analyzer rule.
This appendix provides technical information that describes how user routines are called.

Loading the User Routine into Memory


Control-M/Analyzer loads the user routine once into memory. The rule invocation branches to the user
routine in memory using a BALR R14,R15 instruction. After the user routine exists in memory,
Control-M/Analyzer can branch to the user routine as many times as needed.
During a Control-M/Analyzer invocation, the user routine is loaded when needed by the specified rule
(provided the user routine is not already loaded into memory). When the Control-M/Analyzer invocation
terminates, the user routine is deleted from memory. The same process occurs when Control-M/Analyzer
is invoked by Control-M (by statement DO CTBRULE).
When Control-D invokes Control-M/Analyzer, the user routine is loaded when needed by the specified rule
(provided the user routine is not already loaded into memory). Because Control-D processes DO
statements on a page-by-page basis, all specified DO CTBRULE commands are executed concurrently
(such as, Control-M/Analyzer could be invoked several times). The user routine can be accessed by any or
all of these Control-M/Analyzer invocations. The user routine remains in memory until the last Control-D
page has been processed by Control-M/Analyzer.
It is not required that the user routine be marked reentrant or reusable. Many calls may be made to the
same copy of the routine. Therefore, the routine must be "logically" reusable.

675
Control-M/Analyzer User Guide

Register Usage
Linkage follows standard IBM conventions.

Input Registers
Table 312 Control-M/Analyzer Input Registers

Register Purpose

1 Points to the argument list passed by a DO CALLUSER atatement.


For more information, see Argument Pointers (on page 677).

13 Points to the caller save area.

14 Contains the return address.

Output Registers
Table 313 Control-M/Analyzer Output Registers

Register Purpose

15 Contains the user routine return code. This code should be placed in
Register 15 before the user routine terminates.

Note: The return code can be accessed by the Control-M/Analyzer


rule by means of the SYSURC System variable.

676
Control-M/Analyzer User Guide

Argument Pointers
Upon entry to the user routine, Register 1 points to the list of arguments passed through the DO
CALLUSER statement. The pointer in Register 1 accesses the argument values as diagrammed below:
Table 314 Argument Pointer in Register 1

Register 1
Pointer to address of Argument Address
Argument Address List Þ List Argument Variables

Address of Argument 1 Þ Length Value

Address of Argument 2 Þ Length Value

Address of Argument 3 Þ Length Value

... ... ...

Address of Argument n Þ Length Value

Register 1 points to a list of addresses. The first of these addresses points to a list of argument
addresses. Each argument address in this list points to the physical location of the data (variables).
Each variable is 101 bytes in length. The first byte contains the length of the variable. The remaining 100
bytes contain the value of the variable.
The user may change the variable value. If (as a result of changing the variable value) the length is
changed, the user is responsible for updating the length information in the first byte of the variable.
A sample member, CTBCALLU, is provided in the IOA.SAMPLE library.

677
15
15
D Euro Support
Control-M/Analyzer Euro support enables Control-M/Analyzer rules to validate data before and after
implementing Euro currency conversion in data and application software. The user can easily compare an
original file or report, to a target file or report produced by a new or changed program. A report is
produced that highlights differences while ignoring Euro currency-specific changes produced by the new
or changed program.
For example, Euro support enables the user to easily compare two data sets without needing to process
them sequentially even if only one data set contains Euro currency values. Euro support contains
intelligent compare functionality that is critical during the testing and automated QA processing of Euro
currency conversions.

Euro Support Objectives


1. Test files before and after conversion to Euro currency
• convert local currencies to the Euro in report input and output
• process multiple currencies (including the Euro)
• replace local currencies with the Euro
• produce a bridge to programs not supporting Euro currency
• convert currency data in the input or output of existing software

Method of Operation
Control-M/Analyzer reads currency exchange rates to convert monetary values from one currency to
another. These exchange rates, that are entered by the user using an external AutoEdit currency rates
member, can be updated without changing Control-M/Analyzer rules. The values to be converted can
reside in any data set, report, or local variable file that Control-M/Analyzer can access.
The ON COMPARE block or MSUBSTMASK function can be used to convert currency values from one
currency to another using the AutoEdit currency rates member. The user can specify SUBSTFROM and
SUBSTTO substitution masks for the ON COMPARE block or MSUBSTMASK function. In the SUBSTTO
mask, the user can describe a record layout with currency masks for numeric values that usually
represent currency amounts in the file or report.
When Control-M/Analyzer matches a numeric value to a validation mask, which is described in Validation
Mask (on page 681), it calculates a local currency value for that item based on the specified currency for
the data.
When Control-M/Analyzer receives a format mask, which is described in Format Mask (on page 682), it
converts the source currency value into the required currency using the appropriate AutoEdit currency
exchange rate, and formats the target currency value to match the specified mask.

678
Control-M/Analyzer User Guide

Implementing Euro Currency Support


Perform the following steps to use Control-M/Analyzer Euro Support:
1. Create an AutoEdit member containing currency rates for Control-M/Analyzer conversions. For more
information, see "Creating Currency Rates AutoEdit Member" below.
2. Using an ON COMPARE block or any other Control-M/Analyzer method, create a rule to use the
Currency Rates AutoEdit member for currency conversions. For more information, see Euro Validation
Rule Example (on page 683).

Creating Currency Rates AutoEdit Member


The AutoEdit member for currency rate conversion can reside in any user source library. This member
should contain the following variables:
%%LOCAL_CURRENCY=xxx

Mandatory. Local currency used at the site. The local currency is specified by selecting a three letter
variable from the variables listed in the member. For example, %%LOCAL_CURRENCY=DLR
%%ROUND_CURRENCY=[YES | NO]

Mandatory. What to do when one or more digits after the decimal point cannot fit into the space allowed
by the format mask. These digits can be truncated or rounded to the right-most digit that fits in the mask.
For example, %%ROUND_CURRENCY=NO

Examples
Figure 409 Example of Use of AutoEdit for Currency Conversion
Format Item Price %%ROUND_ Formatted
Mask to Format CURRENCY Price
------ ---------- -------- ---------
###.## 123.121 NO 123.12
###.## 123.234 NO 123.23
###.## 123.645 NO 123.64
###.## 123.858 NO 123.85
###.## 123.121 YES 123.12
###.## 123.234 YES 123.23
###.## 123.645 YES 123.65
###.## 123.858 YES 123.86
%%xxx=value
%%yyy=value

679
Control-M/Analyzer User Guide

These 3-letter variables specify the currencies to be used for conversions and their conversion rates in
terms of the local currency. One or more variables of this type can be specified in the member. The
names of these variables are determined by the user and should match the variable names used in
applicable Control-M/Analyzer rules. For example, the PROD.LIB.AUTOEDIT(CURRATES) member may
contain the following specification:
%%LOCAL_CURRENCY=DLR
%%ROUND_CURRENCY=NO
%%DLR=1
%%EUR=1.106
%%PND=1.629
%%MRK=0.5618

In this example, the local currency is the US Dollar. At the time of this specification, one US Dollar was
equivalent to 1.106 European Union Euro, 1.629 British Pound, and 0.5618 Deutsche Mark.

Currency Mask
A currency mask can be used for currency specification in string substitutions for the ON COMPARE
statement or the MSUBSTMASK function. The currency mask must be matched to validate and format a
value specified in a specific currency on the file or report. The output of a currency mask is a value in the
numeric format that is enclosed within the innermost parentheses of the mask. This value is computed in
the currency specified to the left of these parentheses.
A currency mask is specified as a substring of the SUBSTTO string in the ON COMPARE statement or
MSUBSTMASK function, in the following format:
xxx=(validation mask | format mask[,%yyy=(format mask)])

In this format
 xxx – 3-character currency identifier variable, from the currencies defined in the currencies AutoEdit
member (see above). It specifies the source currency for conversion input.
 yyy – 3-character currency identifier variable, from the currencies defined in the currencies AutoEdit
member (see above). It specifies the target currency for conversion output.
 mask – validation or format pattern that the input must match, as follows:
• + – positive number sign for formatting
• - – negative number sign for formatting
• ? – any single digit (0-9) for validation
• # – any single digit (0-9) for formatting
• Z – any single digit (0-9) for formatting – replace leading zeros with blanks
• . – decimal point (SYSDECCHAR value dependent)
• , – thousands separator (SYSDECCHAR value dependent)

680
Control-M/Analyzer User Guide

Examples of currency masks


%DLR=(mask) = value in Dollars
%PND=(mask) = value in Pounds
%EUR=(mask) = value in Euros

Validation Mask
A validation mask indicates how to read the source currency value. A validation mask is composed only of
question marks (?) with one optional decimal point indicator (comma or dot, based on the SYSDECCHAR
value). The validation mask is used to match a value from a record or string to a formatted currency value
(see above).
Note: A validation mask cannot contain any of the following characters: + (plus), – (minus), Z (letter Z),
# (number sign), or a thousands separator.
The currency value that is to be matched by the validation mask can contain one optional + or – sign, one
optional decimal point indicator (comma or dot, based on the SYSDECCHAR value), and optional
thousands separators.
The examples in Figure 410 illustrate currency values and validation masks to read them.
Figure 410 Validation Masks to Read Currency Values
Validation Mask Currency Value Value Read As SYSDECCHAR
--------------- -------------- ------------- ----------
??????.?? " 1102.31" 1102.31 DOT
" -102.31" -102.31 DOT
" 20.0 " 20.0 DOT
" - 3.92" -3.92 DOT
" 3.9-" -3.9 DOT
" .48" 0.48 DOT
"12,304.99" 12304.99 DOT
" +1102.31" 1102.31 DOT
" 1102.3-" -1102.3 DOT

???????,?? " 1102,31" 1102.31 COMMA


" -102,31" -102.31 COMMA
" 20,0 " 20.0 COMMA
" - 3,92" -3.92 COMMA
" 3,9-" -3.9 COMMA
" ,48" 0.48 COMMA
"112.304,99" 112304.99 COMMA
" +1102,31" 1102.31 COMMA
" 1102,3-" -1102.3 COMMA

681
Control-M/Analyzer User Guide

Format Mask
A format mask indicates how to format the target currency value. A format mask is composed of the
following characters:
 An optional + (plus sign) or – (minus sign)
 At least one Z (letter Z) or # (number sign)
 One optional decimal point indicator (comma or dot, based on SYSDECCHAR value)
A format mask is used to format the value matched by the validation mask into a specific numeric pattern.
The format examples in Table 315 have the following defaults:
SYSDECCHAR=DOT
%%ROUND_CURRENCY=YES

Table 315 Formatting values using a format mask

Value to Format Mask


Format

###.## ZZZ.ZZ Z,ZZZ.## -###.## +ZZZ.## ###.##- ZZZ.ZZ- ###.##+ +ZZZ.##

102.319 102.32 102.32 102.32 102.32 +102.32 102.32 102.32 102.32+ +102.32

20.0 020.00 20.00 20.00 020.00 +20.00 020.00 20.00 020.00+ +20.00

20.03 020.03 20.03 20.03 020.03 +20.03 020.03 20.03 020.03+ +20.03

.03 000.03 .03 .03 000.03 +.03 000.03 .03 000.03+ +.03

3.9+ 003.90 3.90 3.90 003.90 +3.90 003.90 3.90 003.90+ +3.90

3.9- -03.90 -3.90 -3.90 -003.90 -3.90 003.90- 3.90- 003.90- -3.90

3.0- -03.00 -3.00 -3.00 -003.00 -3.00 003.00- 3.00- 003.00- -3.00

.484 000.48 .48 .48 000.48 +.48 000.48 .48 000.48+ +.48

. 000.00 .00 .00 000.00 +.00 000.00 .00 000.00+ +.00

9999.999 ****** ****** 9,999.99 ******* ******* ******* ******* ******* *******

-999.999 ****** ****** ******** ******* ******* ******* ******* ******* *******

Note: If the value of SYSDECCHAR is COMMA, the decimal point indicator is a comma and the thousands
separator is a period.
If overflow of significant digits occurs during formatting, the formatted value will consist entirely of
asterisks.
If one or more blanks occur between a plus or minus sign on the left and a number on the right, the sign
is shifted to the right until it is adjacent to the number.

682
Control-M/Analyzer User Guide

Validation and Format Masks


When replacing a currency value specified in one currency by a currency value specified in another
currency, as opposed to adding an additional currency value to the record, the currency mask should
specify both a validation mask and format mask. The attributes of the value in the target currency
(length, precision, and so on) can differ from the attributes of the value in the source currency. The
syntax of the format mask is
%xxx=(validation mask,%yyy=(format mask))

In this syntax, xxx is the source currency and yyy is the target currency for the conversion.

Validation and format mask examples:


Convert source value in Dollars to Euros:
%DLR=(??????.??,%EUR=(######.##))

Convert source value in Pounds to Dollars:


%PND=(????.??,%DLR=(#####.##))

Euro Validation Rule Example


The rule below validates a new column in the report, listing Euro currency values for items previously
listed only in dollars. In this example, all values except one (with the Euro amount value 1.00 in the
illustration below) were correctly calculated.

683
Control-M/Analyzer User Guide

Input Data
Table 316 Euro Validation Rule Example – Before
DD BEFORE DD Statement
GLOBAL BANK INC.
PAGE: 1
*******************************
C U S T O M E R L I S T I N G
*******************************

OPEN DEPOSIT ENDING DIVIDEND


DATE AMOUNT ($) BALANCE ($) PAID ($)
===== ========== =========== ========
02/04/1999 3000.00 3472.88 472.88
09/08/1998 7500.00 9116.30 1616.30
01/02/2002 -1000.00 9.24 -980.76
03/06/1999 10000.00 12762.82 2762.82
09/07/1999 8000.00 8422.65 422.65
02/05/1997 5000.00 5677.99 677.99
09/09/1999 9500.00 9716.30 216.30
02/04/1996 3000.00 3472.88 472.88
09/08/1999 7500.00 9116.30 1616.30
01/22/2003 2000.00 19.24 -1980.76
03/06/1998 10000.00 12762.82 2762.82
09/07/2001 8000.00 7277.47 -722.53
12/05/1998 5000.00 5677.99 677.99
09/09/1999 9500.00 9716.30 216.30

Table 317 Euro Validation Rule Example – After


DD#AFTER DD Statement
GLOBAL BANK INC.
PAGE: 1
*******************************
C U S T O M E R L I S T I N G
*******************************

OPEN DEPOSIT ENDING DIVIDEND EURO


DATE AMOUNT ($) BALANCE ($) PAID ($) AMOUNT
===== ========== =========== ======== ======
02/04/1999 3000.00 3472.88 472.88 2712.47
09/08/1998 7500.00 9116.30 1616.30 6781.19
01/02/2002 -1000.00 9.24 -980.76 -904.15
03/06/1999 10000.00 12762.82 2762.82 9041.59
09/07/1999 8000.00 8422.65 422.65 7233.27
02/05/1997 5000.00 5677.99 677.99 4520.79
09/09/1999 9500.00 9716.30 216.30 8589.51
02/04/1996 3000.00 3472.88 472.88 1.00
09/08/1999 7500.00 9116.30 1616.30 6781.19
01/22/2003 2000.00 19.24 -1980.76 1808.31
03/06/1998 10000.00 12762.82 2762.82 9041.59
09/07/2001 8000.00 7277.47 -722.53 7233.27
12/05/1998 5000.00 5677.99 677.99 4520.79
09/09/1999 9500.00 9716.30 216.30 8589.51

684
Control-M/Analyzer User Guide

Testing Rule
Figure 411 Testing Euro Validation Rule Example
EXECUTE 'INIT'
ON_DATA
ALWAYS
DO GETMEM MEMSYM 'EURO01' LIBSYM 'N14.LIB.AUTOEDIT'
DO PRINT DATA 'LOCAL CURR=%%LOCAL_CURRENCY'
DO PRINT DATA 'ROUND CURR=%%ROUND_CURRENCY'
DO PRINT DATA 'EUR=%%EUR DLR=%%DLR'
EXECUTE 'RECONCIL'
ON_COMPARE
SOURCE1
DD 'DDBEFORE' PROCESS USERBLOCK 'SUBSDATE'
SOURCE2
DD 'DD#AFTER'
ON_PARM MODE DS LINECT 80
WHEN FLINE 1 TLINE 80 FCOL 1 TCOL 80 SEARCH '.AL.'
DO EXTRACT 'LINE' LEVEL 0 LINE +0 FCOL 1 TCOL 80
DO SET 'DIFFLINE' EVAL 'SYSCURLINE'
DO SET 'LINETYPE' EVAL 'SUBSTR(1,1,LINE)'
DO PRINT DATA '-%%LINETYPE- %%DIFFLINE'

EXECUTE 'END'
ON_DATA
ALWAYS
DO TERMINATE RESULT OK USER_CODE 00

EXECUTE 'SUBSDATE'
ON_DATA
ALWAYS
DO SET 'RC' EVAL 'MSUBSTMASK(''DDSUBST'',SYSCURLINE)'

JCL for Running the Test


//STEP01 EXEC CONTROLB,RULE=EURO01,GROUP=INTRAC
//DDBEFORE DD DISP=SHR,DSN=N14.LIB.REPORT(EURO01#1)
//DD#AFTER DD DISP=SHR,DSN=N14.LIB.REPORT(EURO01#2)
//DDSUBST DD *
SUBSTFROM 'DIVIDEND' SUBSTTO 'DIVIDEND EURO' EOS
SUBSTFROM 'PAID ($)' SUBSTTO 'PAID ($) AMOUNT' EOS
SUBSTFROM '========== =========== ========'
SUBSTTO '========== =========== ======== ======' EOS
SUBSTFROM '??/??/???? ??????.?? ??????.?? ?????.??'
SUBSTTO '??/??/???? %DLR=(??????.??) ??????.?? ?????.?? %EUR=(ZZZZZZ.ZZ)'
EOS

AutoEdit Member
%%LOCAL_CURRENCY=DLR
%%ROUND_CURRENCY=NO
%%DLR=1
%%EUR=1.106

685
Control-M/Analyzer User Guide

Output Data
LOCAL CURR=DLR
EUR=1.106 DLR=1
-R-
-D- 02/04/1999 3000.00 3472.88 472.88 2712.47
-I- 02/04/1999 3000.00 3472.88 472.88 1.00

686
16
16
E TRACE Facility
Control-M/Analyzer supports the execution of the TRACE facility, to examine the Control-M/Analyzer
commands while a rule is executing and after its termination. When a trace run is requested, and during
rule execution, the Control-M/Analyzer commands of the rule being executed are printed by block.
This appendix provides technical information that describes how trace runs are activated, provides an
example describing the operation of the TRACE facility on a sample rule, and describes the output
produced by the TRACE facility. For additional information and complete documentation of the IOA TRACE
facility and the trace level list, see the INCONTROL for z/OS Administrator Guide.

Activating the TRACE facility


To activate the TRACE facility and apply it to determine the proper operation of a rule, add the following
DD to the JCL of the rule you want to trace:
//DATRCIN DD *
TRACE=0100:0100
/*

Applying the TRACE facility to a rule


When the TRACE facility is applied to a particular rule, you can receive a printout, by block, of the
executed Control-M/Analyzer commands. This printout becomes available even as the rule is executing.
An example of this process is shown below.
Assume the rule to which the TRACE facility is to be applied is that illustrated in Figure 412
Figure 412 Applying the TRACE Facility to a Rule
EXECUTE ‘INIT’
ON_DATA
IF ‘NOT(ISVAR(DB_INTRAC.FOU))’
DO GOTO ‘NOCHK’
IF ‘DB_INTRAC.FOU>1’
DO PRINT DATA ‘FOU is greater than 1’
LABEL ‘NOCHK’
ALWAYS
DO SET ‘MYVAR’ EVAL ‘1.000’
DO PRINT DATA ‘’’TEXT %%MYVAR ‘’’ FORMAT VARNAME ‘MYVAR’
LENGTH 5 PREC 1 DELIMITER ‘Y’

687
Control-M/Analyzer User Guide

When the rule is run, its output, as shown in DATRACE sysout, is that illustrated in Figure 413.
Figure 413 Output of Rule to Which TRACE Facility Was Applied
********************************* TOP OF DATA *******************
CTBTRC : ** ENTERING BLOCK: INIT OF TYPE DATA
CTBTRC : ON DATA
CTBTRC : IF
CTBTRC : DO GOTO
CTBTRC : DO SET
CTBTRC : DO PRINT
******************************** BOTTOM OF DATA ******************

688
17
17
F Single Startup API
The Single Startup Application Programming Interface (API) enables a user program to make multiple
calls to a Control-M/Analyzer rule after performing a single startup of the Control-M/Analyzer Runtime
environment.
The Control-M/Analyzer Runtime environment can be invoked by a call from a user program. Further
details can be found in the Control-M/Analyzer User Guide. When not using the Single Startup API, each
invocation of a Control-M/Analyzer rule from a user program normally causes the following actions:
1. Load SAS/C modules, Control-M/Analyzer modules and the invoked rule.
2. Initiate the Control-M/Analyzer Runtime environment and the invoked rule.
3. Compile the invoked rule.
4. Execute the invoked rule.
5. Delete loaded modules from memory.
6. Terminate the invoked rule and the Control-M/Analyzer Runtime environment.
When using the Single Startup API, the startup and termination phases are performed only once. For
example, a program that sends each record of a file to a Control-M/Analyzer validation rule in a loop does
not perform Steps 1, 2, 3, 5 and 6 (above) for each rule invocation. Instead, Steps 1, 2 and 3 are
performed only on first invocation and Steps 5 and 6 are performed only on the last invocation.

Runtime Environment – Description


The Single Startup API provides the calls to Control-M/Analyzer that are described in Table 318.
Table 318 Calls Provided by Single Startup API

Call Effect

INIT Performs initialization routines, attaches Control-M/Analyzer, and so


on.

CHECK Executes the preloaded and precompiled user rule.

KILL Performs termination actions, detaches Control-M/Analyzer, and so


on.

689
Control-M/Analyzer User Guide

Required User Actions


Perform the following steps in order to use the Single Startup API to Control-M/Analyzer:
1. Replace the regular CALL CONTROLB of the calling user program, with the calls described in
Table 319.
Table 319 Calls to Replace Regular CALL CONTROLB

Call Type From assembler user program From COBOL user program

INIT CALL CTBSSCL,(OPTINIT,RULE, CALL 'CTBSSCL' USING INIT, RULE,


MISSION,GRP,RULENAME) MISSION, GRP, RULENAME.

CHECK CALL CTBSSCL,(OPTCHECK,LINEL, CALL 'CTBSSCL' USING CHECK,


LINEID,TOLER) LINEST, LINEID, TOLER.

KILL CALL CTBSSCL,(OPTKILL) CALL 'CTBSSCL' USING KILL.

2. Create a Control-M/Analyzer rule named "TSTCHECK", to perform all necessary checks for the lines
read by the user program. An example of this rule is provided below.

API Documentation
The Single Startup API interface has the components described in Table 320
Table 320 Components of the Single Startup API Interface

Name Description

USER PROGRAM User program module invoking Control-M/Analyzer services

CTBSSCL Interface module between Control-M/Analyzer and the user program

CTBSSSM Interface rule between Control-M/Analyzer and the user check rule

TSTCHECK Rule that does the user validation checks and actions

CTBSSGET Interface between rule CTBSSSM and module CTBSSCL

The USER PROGRAM module and TSTCHECK rule must be provided by the user. All other components are
supplied with the Single Startup API and should not be changed.

690
Control-M/Analyzer User Guide

Execution Logic
The diagram below illustrates the sequence of invoked actions:
Figure 414 Sequence of Invoked Actions

USER PROGRAM issues a call to the CTBSSCL module with OPTION=INIT. The CTBSSCL module performs
the initial settings, suspends execution of the USER PROGRAM, and attaches Control-M/Analyzer as a
subtask.
Control-M/Analyzer is started and the CTBSSSM rule is called. This rule initializes the interface and should
not be changed. The CTBSSSM rule is executed up to (but not including) the statement GET: CALL
CTBSSGET (…….). The Control-M/Analyzer subtask is suspended and the USER PROGRAM resumes
execution.
Each time USER PROGRAM gets a record, it calls the CTBSSCL module with OPTION=CHECK. The USER
PROGRAM task is moved into wait state and the Control-M/Analyzer subtask continues execution using
the record that was received from the USER PROGRAM. The CTBSSGET routine retrieves the contents of
the record that was passed as a parameter, stores the contents of the record in corresponding
Control-M/Analyzer variables, and calls the TSTCHECK rule, passing to it the arguments LINE, LINEID and
TOLER.

691
Control-M/Analyzer User Guide

The TSTCHECK rule is loaded and compiled only once during the session. Each subsequent call simply
passes new parameter values to it. The TSTCHECK rule performs the required checks and returns the
LINE and TOLER parameters to the USER PROGRAM. (These parameters can be changed by the rule.)
The Control-M/Analyzer subtask is suspended and the USER PROGRAM gets the next record.
After the last record has been checked, USER PROGRAM calls the CTBSSCL module with OPTION=KILL.
The CTBSSCL module detaches Control-M/Analyzer and USER PROGRAM ends execution.

Examples
Assembler
The CTBSSM program, a sample assembler program, illustrates how to call a Control-M/Analyzer rule from
a user program using the Single Startup API. This program is a member in the IOA SAMPLE library.
The program reads an input file using DD-USERIN, passes each record to Control-M/Analyzer that in turn
executes the TSTCHECK rule to validate the record. As a result, the TSTCHECK rule returns TOLER (return
code) that is being printed in the main cycle of the program illustrated in Figure 415.

692
Control-M/Analyzer User Guide

Figure 415 Example - Assembler


USERMAIN CSECT
ENTRY USERMAIN
CNOP 0,4 PROLOG ROUTINE
USING *,13
B 80(0,15)
DC 17F'0'
DC AL1(6)
DC C'DB2CTB'
ST 13,4(0,15)
ST 15,8(0,13)
STM 14,12,12(13)
LR 13,15
*
OPEN (USEROUT,OUTPUT)
OPEN (USERIN,INPUT)
* INITIALIZATION
CALL CTBSSCL,(OPTINIT,RULE,MISSION,GRP,RULENAME)
****************************************************************
CYCLE EQU * MAIN CYCLE
GET USERIN,LINE
PUT USEROUT,LINE
* CHECK THE LINE VIA USERRULE - "TSTCHECK"
CALL CTBSSCL,(OPTCHECK,LINEL,LINEID,TOLER)
*
L R2,LINEID just to show how that it can be changed
LA R2,1(R2)
ST R2,LINEID
*
L 15,TOLER PRINT VALUE OF TOLER RETURNED FROM CTB
CVD 15,DWORD
UNPK WORD16(16),DWORD(8)
OI WORD16+15,X'F0'
MVC RCWORD,WORD16+8
PUT USEROUT,PTOLER
*
B CYCLE CONTINUE CYCLE
**************************** END OF FILE SITUATION *******************
EOFUSIN EQU *
CLOSE (USERIN)
CLOSE (USEROUT)
*
CALL CTBSSCL,(OPTKILL)
B RETOK
**********************************************************************
RETOK EQU *
SR 15,15 NORMAL EXIT.
L 13,4(0,13)
L 14,12(13,0)
LM 0,12,20(13)
MVI 12(13),X'FF'
BR 14
**********************************************************************
RETNOTOK EQU *
LA 15,8 BAD EXIT.
L 13,4(0,13)
L 14,12(13,0)
LM 0,12,20(13)
MVI 12(13),X'FF'
BR 14
*----------------------------------------------
USERIN DCB DSORG=PS,MACRF=(GM),DDNAME=USERIN,EODAD=EOFUSIN
USEROUT DCB DSORG=PS,MACRF=(PM),DDNAME=USEROUT
*******************************************************************
* FIELDS LINEL and LINE SHOULD BE DEFINED ONE AFTER ANOTHER AS BELOW !
LINEL DC H'80' length of the read line=80 for this case
LINE DS CL100 !!! THIS FIELD SHOULD BE NOT LESS THAN 100 !

693
Control-M/Analyzer User Guide

*******************************************************************
LINEID DC F'1'
TOLER DS F
*
OPTINIT DC CL8'INIT'
OPTCHECK DC CL8'CHECK'
OPTKILL DC CL8'KILL'
RULE DC CL8'CTBSSSM'
MISSION DC CL8' '
GRP DC CL8'TSTGROUP'
RULENAME DC CL8'TSTCHECK'
*
PTOLER DC C'TOLER = '
RCWORD DS CL8
DC CL132' '
WORD16 DS CL16
DWORD DS D
LTORG
END

The TSTCHECK rule is listed in Figure 416.


Figure 416 The TSTCHECK rule
+--------------------------------------------------------------------------+
OWNER OWNER1 GROUP MYGROUP
UPDATED 08/08/99 - 16:17:30 BY U-52
DESC
OPTIONS
===========================================================================
EXECUTE CHECK UPON C
ON DATA
ALWAYS
DO PRINT = RARG01=REPLACE(RARG01,'CARD','BARD') F C
DO PRINT = TSTCHECK: LINE=(%%RARG01) F C
DO PRINT = TSTCHECK: LINEID=(%%RARG02) F C
DO PRINT = TSTCHECK: TOLER=(%%RARG03) F C
DO SET = RARG03=RARG03+1 C
DO PRINT = TSTCHECK:+1 TOLER=(%%RARG03) F C
===========================================================================
EXECUTE UPON C
ON
======= >>>>>>>>>>>> END OF RULE DEFINITION PARAMETERS <<<<<<<<<<<<<<< =====

PLEASE FILL IN RULE DEFINITION. 13.54.17

The TSTCHECK rule receives the parameters RARG01 – RARG03 from Control-M/Analyzer.
The RARG01 parameter contains the record to be checked. The RARG02 parameter points to the LINEID
(record logical sequence number). The RARG03 parameter refers to TOLER (return code). The values
RARG01 and RARG03 can be changed by TSTCHECK and their updated values are passed to the USER
PROGRAM. Changes in the RARG02 parameter are not returned to the USER PROGRAM.
Input for the USERMAIN Assembler program (sample user program CTBSSM) is illustrated in Figure 417.
Note: This is sample code for documentation only. Please refer to the IOA SAMPLE(CTBSSSM) for the
complete source code to be used.

694
Control-M/Analyzer User Guide

Figure 417 Input for the USERMAIN Assembler program


CARD 01
CARD 02
CARD 03
CARD 04
CARD 05

The output from the USERMAIN program is illustrated in Figure 418.


Figure 418 Output from the USERMAIN program
CARD 01
BARD 01
TOLER = 00000001
CARD 02
BARD 02
TOLER = 00000002
CARD 03
BARD 03
TOLER = 00000003
CARD 04
BARD 04
TOLER = 00000004
CARD 05
BARD 05

The output from the TSTCHECK rule is illustrated in Figure 419.


Figure 419 Output from USERCHECK Rule
TSTCHECK: LINE=(BARD 01
TSTCHECK: LINEID=(00000001)
TSTCHECK: TOLER=(1)
TSTCHECK:+1 TOLER=(2.000)
TSTCHECK: LINE=(BARD 02
TSTCHECK: LINEID=(00000002)
TSTCHECK: TOLER=(2.000)
TSTCHECK:+1 TOLER=(3.000)
TSTCHECK: LINE=(BARD 03
TSTCHECK: LINEID=(00000003)
TSTCHECK: TOLER=(3.000)
TSTCHECK:+1 TOLER=(4.000)
TSTCHECK: LINE=(BARD 04
TSTCHECK: LINEID=(00000004)
TSTCHECK: TOLER=(4.000)
TSTCHECK:+1 TOLER=(5.000)
TSTCHECK: LINE=(BARD 05
TSTCHECK: LINEID=(00000005)
TSTCHECK: TOLER=(5.000)

695
Control-M/Analyzer User Guide

COBOL
The example in Figure 420 shows how to use the same interface with a COBOL user program.
Figure 420 Example - COBOL
. . . . . . . . . . . . . . . . .
WORKING-STORAGE SECTION.
. . . . . . . . . . . . . . . . .
01 INIT PIC X(8) VALUE 'INIT'.
01 CHECK PIC X(8) VALUE 'CHECK'.
01 KILL PIC X(8) VALUE 'KILL'.
01 RULE PIC X(8) VALUE 'CTBSSSM'.
01 MISSION PIC X(8) VALUE ' '.
01 GRP PIC X(8) VALUE 'TSTGROUP'.
01 RULENAME PIC X(8) VALUE 'TSTCHECK'.
01 LINEST.
05 LINEL PIC 999 USAGE BINARY.
05 LINE1 PIC X(100).
01 LINEID PIC S9(6) USAGE BINARY.
01 TOLER PIC S9(6) USAGE BINARY.
. . . . . . . . . . . . . . . . . . . . . . . .
PROCEDURE DIVISION.
. . . . . . . . . . . . . . . . . . . . . . . . . . .
CALL 'CTBSSCL' USING INIT, RULE, MISSION, GRP, RULENAME.
. . . . . . . . . . . . . . . . . . . . . . . . . . .
CALL 'CTBSSCL' USING CHECK, LINEST, LINEID, TOLER.
. . . . . . . . . . . . . . . . . . . . . . . . . . .
CALL 'CTBSSCL' USING KILL.

696

You might also like