JOBREC
Purpose
This statement defines the fault-tolerant workstation job
properties. You must specify JOBREC for each member
of the SCRPTLIB. For each job this statement specifies
the script or the command to run and the user that must run the script
or command.
Format
Parameters
- JOBSCR(script name)
- Specifies the name of the shell script or executable file to run for the job. The maximum length is 4095 characters. If the script includes more than one word, it must be enclosed within single or double quotation marks. Do not specify this keyword if the job uses a centralized script.
- JOBCMD(command name)
- Specifies the name of the shell command to run the job. The maximum length is 4095 characters. If the command includes more than one word, it must be enclosed within single or double quotation marks. Do not specify this keyword if the job uses a centralized script.
- JOBUSR(user name)
- Specifies the name of the user submitting
the specified script or command. The maximum length is 47 characters.
If you do not specify the user in the
JOBUSRkeyword, the user defined in theCPUUSERkeyword of theCPURECstatement is used. TheCPURECstatement is the one related to the workstation on which the specified script or command must run. If the user is not specified in theCPUUSERkeyword, the tws user is used.If the script is centralized, you can also use the job-submit exit (
EQQUX001) to specify the user name. This user name overrides the value specified in theJOBUSRkeyword. In turn, the value specified in theJOBUSRkeyword overrides that specified in theCPUUSERkeyword of theCPURECstatement. If no user name is specified, the tws user is used.If you use this keyword to specify the name of the user who submits the specified script or command on a Windows™ fault-tolerant workstation, you must associate this user name to the Windows™ workstation in the
USRRECinitialization statement. - INTRACTV(YES|NO)
- Specifies that a Windows™ job runs interactively on the Windows™ desktop. This keyword is used only for jobs running on Windows™ fault-tolerant workstations.
- RCCONDSUC("success condition")
- An expression which determines the return code (RC) required
to consider a job as successful. If you do not specify this keyword, a return code of zero
corresponds to a successful condition. A return code different from zero corresponds to the
job abending.
The success condition maximum length is 256 characters and the total length of
JOBCMDorJOBSCRplus the success condition must be 4086 characters. This is because theTWSRCMAPstring is inserted between the success condition and the script or command name. For example the dir command together with the success condition"rc<4"is translated intodir TWSRCMAP: RC<4.The success condition expression can contain a combination of comparison and Boolean expressions:
- Comparison expression
- Specifies the job return codes. The syntax is:
(RC operator operand)- RC
- The RC keyword.
- operator
- Comparison operator. It can have the following values:
Table 1. Comparison operators Example Operator Description RC<a < Less than RC<=a <= Less than or equal to RC>a > Greater than RC>=a >= Greater than or equal to RC=a = Equal to RC<>a <> Not equal to - operand
- An integer between -2147483647 and 2147483647.
RCCONDSUC "(RC <= 3)" - Boolean expression
- Specifies a logical combination of comparison expressions. The syntax is:
comparison_expression operator comparison_expression- comparison_expression
- The expression is evaluated from left to right. You can use parentheses to assign a priority to the expression evaluation.
- operator
- Logical operator. It can have the following values:
Table 2. Logical operators Example Operator Result expr_a and expr_b And TRUE if both expr_a and expr_b are TRUE. expr_a or expr_b Or TRUE if either expr_a or expr_b is TRUE. Not expr_a Not TRUE if expr_a is not TRUE.
RCCONDSUC "(RC<=3) OR ((RC<>5) AND (RC<10))"