Modifying Event Definition for BS2000 Job

This document covers the following topics:


Modifying an Event Definition

Start of instruction set To modify an existing event definition

  1. Type M in the line command field of the selected event on the End-of-Job Checking and ActionsScreen.

  2. Press Enter.

  3. The Modify Event Definition window opens with the current values for the event. You can modify the values by overtyping them.

  4. When you are finished defining the event, you can proceed as follows:

Note:
The modify option (M line command) is available at the event level (job step) only.

See the following examples of U-type (user switch), V-type (job variable) and J-type (special event) event definitions and for examples of R-type (user exit) and S-type (string search) event definitions.

Example of an S-type Event

(BS2000)

 24.06.08               ***** Entire Operations *****                 13:55:13 
 Ow +---------------------------------------------------------------------+    
 Ne !                                                                     !    
 -- !                 Modify Event Definition                             ! ---
 C  !                                                            BS2000   !  OA
 m  !    Event Type ==> S  R  User Exit        J  Job special event       !    
 _  !                      S  String           A  Add. Job-ok, Job-not-ok !    
 _  !                      U  User Switch                                 !    
 _  !                      V  Job Variable                                !    
 _  !                                                                     !    
 _  !  User Exit ==> ___________ in Natural Library ==> ________          !    
 _  !                                                                     !    
 _  !  String  ==> ABEND_________________________        missing ==> _    !    
 ** !  in File ==> ______________________________________________________ ! ***
 _  !                                   (Optional) Read Password ==>      !    
 _  !                                                    defined ==> no   !    
 -- !  User Switch  ==> 0_ of BS2000 User ID ==> ________                 ! ---
 A  !                                                                     ! her
 P  !  Occurrence of event means OK or NOT OK ==> OK                      ! Set
    !                                                                     !    
 Co ! Enter-PF1---PF2---PF3-----------PF5--------------------------PF12-- !    
Ent !       Help  Add   End           Save                         Menu   ! ---
    +---------------------------------------------------------------------+   

Field Descriptions

String Search - BS2000

Meaning of the input fields:

Field Description
String This string will be searched for in the SYSOUT or any defined file. If the string is found, the event is satisfied. If the search string contains at least one blank at the beginning, in the middle or at the end, it must be enclosed in quotes. For example:
'    leading blanks'

The search string may contain symbols.

Symbols with activation escape characters will be replaced at job activation time.

Symbols with submit escape characters will be replaced at end-of-job checking time.

Missing symbols will cause a permanent activation error or permanent end-of-job checking error.

missing You can negate the string search, if you specify "Y" here.
in File If a BS2000 file is specified here, it will be scanned for the search string. Symbol replacement is possible for the file name or any part of it:
  • with activation escape - once at activation time

  • with submission escape - during EOJ checking

If this field is left blank, the SYSOUT will be scanned. Symbol replacement is possible. The submission escape character is to be used.

Example of a U-type Event

(BS2000)

  24.10.08               ***** Entire Operations *****                    14:04:07
  Ow +---------------------------------------------------------------------+
  Ne !                                                                     !
  -- !                 Add Event Definition                                ! ---
  C  !                                                            BS2000   !  OA
  _  !    Event Type ==> U  R  User Exit        J  Job special event       !
  _  !                      S  String           A  Add. Job-ok, Job-not-ok !
  _  !                      U  User Switch                                 !
  _  !                      V  Job Variable                                !
  _  !                                                                     !
  _  !  User Exit ==> ___________ in NATURAL Library ==> ________          !
  _  !                                                                     !
  _  !  String  ==> ______________________________        missing ==> _    !
  ** !  in File ==> ______________________________________________________ ! ***
  _  !                                   (Optional) Read Password ==>      !
  _  !                                                                     !
  -- !  User Switch  ==> 11 of BS2000 User ID ==> DC1_____                 ! ---
  A  !                                                                     ! her
  P  !  Occurrence of event means OK or NOT OK ==> OK                      ! Rtn
     !                                                                     !
  Co ! Enter-PF1---PF2---PF3-----------PF5--------------------------PF12-- !
 Ent !       Help  Add   End           Save                         Menu   ! ---
     +---------------------------------------------------------------------+

Explanation:

The event is ok if user switch 11 of the BS2000 user ID DC1 is on at job termination time.

Example of a V-type Event

(BS2000)

  24.10.08               ***** Entire Operations *****                    14:09:01
  Ow +---------------------------------------------------------------------+
  Ne !                                                                     !
  -- !                 Add Event Definition                                ! ---
  C  !                                                            BS2000   !  OA
  _  !    Event Type ==> v  R  User Exit        J  Job special event       !
  _  !        +----------------------------------------------------------+ !
  _  !        !                                                          ! !
  _  !        !         Event Definition: Job Variable Checking          ! !
  _  !        !                                                BS2000    ! !
  _  !  User  !  If Contents of Job Variable                             ! !
  _  !        !  $DC1.JV.DEMO__________________________________________  ! !
  _  !  Strin !  at Position 10_ in Length 20_ with Format A             ! !
  ** !  in Fi !  is EQ                                                   ! ! ***
  _  !        !  Result is 100_____________________________________      ! !
  _  !        !  __________________________________________________      ! !
  -- !  User  !                       (Optional) Read Password ==>       ! ! ---
  A  !        !                                                          ! ! her
  P  !  Occur !  The successful Check means OK or NOT OK ==> OK          ! ! Rtn
     !        ! Enter-PF1---------PF3-----------PF5--------------------  ! !
  Co ! Enter- !       Help        End           Save                     ! !
 Ent !        +----------------------------------------------------------+ ! ---
     +---------------------------------------------------------------------+

Explanation:

The event is ok if the job variable $DC1.JV.DEMO contains:

Result is 100

at position 10 in length 20 in alphanumeric format.

Field Descriptions: Event Definition

Job Variable Checking - BS2000

Meaning of the input fields:

Field Description
Job Variable

Enter the name of a valid BS2000 job variable. If the job variable is specified without an explicit user ID, the job default BS2000 user ID is used as prefix. Symbol replacement is performed in the name, if the name contains the activation escape character at least once.

Symbol replacement is possible. The submission escape character is to be used.

at Position  Enter position of job variable substring to be checked. Possible values: 1 through 253.
in Length  Enter length of job variable substring to be checked. Possible values: 1 through 253.
with Format  Enter format in which the job variable substring is to be checked against the comparison string. Possible values:
alphanumeric
numeric
is xx  This is the comparison operator. Enter a logical operator for the comparison of the defined BS2000 job variable substring against the comparison string below. Possible values:
= or EQ  Code is equal to specified value.
>= or GE  Code is greater than or equal to specified value.
> or GT  Code is greater than specified value.
<= or LE  Code is lower than or equal to specified value.
< or LT  Code is lower than specified value.
<> or NE  Code is different from specified value.
(Comparison string)

Enter the string or field to be compared with the job variable substring. The strings are compared in the defined Format.

The content of this field is compared with the substring of the job variable, or it is inserted into the substring of the job variable. The comparison is made in the defined format.

Symbol replacement is possible. The submission escape character is to be used.

(Optional) Read Password If the job variable is read password-protected, specify the password here.

Adding or Modifying a Job Variable

(BS2000)

Start of instruction set To add or modify a job variable in BS2000

  1. Type J in the line command field of the selected event on the End-of-Job Checking and Actions Screen. Press Enter.

  2. The Job Variable Modification window opens with the current values. You can modify the values by overtyping them:

      24.10.08               ***** Entire Operations *****                 14:13:12 
      Owner   SN            End-Of-Job Checking + Actions   BS2000    Job BS2-0001  
      Network +--------------------------------------------------------------------+
      ------- !                                                                    !
      C Actio !   Job ended ok                                                     !
      _       !                Job Variable Modification                           !
      _       !                                                                    !
      _       !  Set Contents of Job Variable                                      !
      _       !  HUGO__________________________________________________            !
      _       !  at Position 1__ in Length 1__ with Format A                       !
      _       !  to                                                                !
      _       !  B_______________________________________________________________  !
      _       !  ________________________________________________________________  !
      ******* !  ________________________________________________________________  !
      j   J   !  ________________________________________________________________  !
      _       !                      (Optional) Write Password ==>                 !
      ------- !                                        defined ==> no              !
      A Activ !                         Execute if temp. Dummy ==> _               !
      P Descr !                                                                    !
              !  Enter--PF1-----PF3-------PF5--------------PF9---------            !
      Command !         Help    End       Save             Delete                  !
     Enter-PF +--------------------------------------------------------------------+
           Help  Add   End         Save        Up    Down                    Menu 
    
    

    If no job variable has been defined on job level, the fields in this window will be empty; you can set a job variable, by entering the values here. When you are finished setting or modifying the variable, you can proceed as follows:

  3. Press PF5 (Save) to save the addition or modification.

  4. Press PF3 (End) to close the window and return to the End-of-Job Checking and Actions Screen.

    Note:
    Symbol replacement is performed in the name, if the name contains the activation escape character at least once.

Field Descriptions: BS2000 Job Variable

Field Description
Job Variable Enter the name of a valid BS2000 job variable. If the job variable is specified without an explicit user ID, the job default BS2000 user ID is used as prefix. Symbol replacement is performed in the name, if the name contains the activation escape character at least once.
at Position  Enter position of job variable substring to be checked. Possible values: 1 through 253.
in Length  Enter length of job variable substring to be checked. Possible values: 1 through 253.
with Format  Enter format in which the job variable substring is to be checked against the comparison string. Possible values:
alphanumeric
numeric
to  Enter the string or field to be set as the job variable or as a substring of the job variable. Symbol replacement will be performed, if the field contains the activaction escape character at least once.
Write Password  If the job variable is write password-protected, specify the password here.
defined This field is for information only. It indicates whether a Write Password is defined or not.
Execute if temporary Dummy If "Y" or "N" is specified here, the End-of-Job action will be executed according to this definition, if the job was executed as a temporary dummy job. If the field is left empty, the defaults for the action apply.

Special PF Keys

You can perform the following function from the Job Variable Modification window using this PF key:

Key Name Function
PF9  Delete  Delete the complete job variable definition.

Example of a J-type Event

(BS2000)

This function enables you to define special events which could occur during job execution. When such an event occurs this always means Job not ok.

  24.10.08               ***** Entire Operations *****                    14:25:28
  Ow +---------------------------------------------------------------------+
  Ne !                                                                     !
  -- !                 Add Event Definition                                ! ---
  C  !                                                            BS2000   !  OA
  _  !    Event Type ==> J  R  User Exit        J  Job special event       !
  _  !        +-------------------------------------------------+ b-not-ok !
  _  !        !                                                 !          !
  _  !        !         Event Definition: Special Event         !          !
  _  !        !                                       BS2000    !          !
  _  !  User  !                                                 !          !
  _  !        !  Event ==> ___                                  !          !
  _  !  Strin !                                                 ! ==> _    !
  ** !  in Fi !                                                 ! ________ ! ***
  _  !        !  The occurrence of this event always has the    ! ==>      !
  _  !        !  meaning 'Job not ok'.                          !          !
  -- !  User  !                                                 !          ! ---
  A  !        !  Enter-PF1-------PF3--------PF5---------------  !          ! her
  P  !  Occur !        Help      End        Save                !          ! Rtn
     !        +-------------------------------------------------+          !
  Co ! Enter-PF1---PF2---PF3-----------PF5--------------------------PF12-- !
 Ent !       Help  Add   End           Save                         Menu   ! ---
     +---------------------------------------------------------------------+

Explanation:

JIR = Job execution interrupted.

This event occurs if an operating system abend or hardware failure occurs during job execution. This is always used when a job did not run on LOGOFF (job ended normally) or ABEND (job interrupted with error). The defined actions are performed after the start of the Monitor.