CHGJOB
The CHGJOB instruction changes the job name associated with the operations of an application occurrence.
This instruction applies only to jobs running in z/OS® environments.
For a description of the keywords that can be used, see Table 1.
Keyword | Requirement | Multiple Values Allowed | Description | Abbreviation | Format |
---|---|---|---|---|---|
APPL() | Required | No | The name of the application to be modified. | ||
OPNO() | Optional | Yes | The number of the operation to be modified. | OP | |
IADATE() | Optional¹ | No | The input arrival date of the application occurrence. IADATE(=) assumes the current date. IADATE() and IA() are mutually exclusive. | IAD | YYMMDD |
IATIME | Optional¹ | No | The input arrival time of the application occurrence. If IADATE(=) is specified, IATIME() assumes that the default input arrival time is specified in the DEFIAT parameter of the EQQYRPRM member. IADATE() and IA() are mutually exclusive. | IAT | HHMM |
IA() | Optional¹ | No | The input arrival date and time of the application occurrence. IA(=) assumes the current date and time. It defaults to the earliest or latest input arrival date and time of the application occurrences found in the current plan, depending on the SORT parameter. IA() cannot be used together with IADATE() or IATIME(). | YYMMDDHHMM | |
OLDJOB() | Optional | No | The old jobname | OLDJ | |
NEWJOB() | Required | No | The new jobname | NEWJ | |
WSNAME() | Optional | No | The operation workstation name | WS | |
Note: ¹
Mutually exclusive with another keyword. |
Note: If you omit the selection parameters OPNO(), OLDJOB(),
or WSNAME(), OCL will change the jobname of all the operations in
the occurrence. You cannot change the jobname of a job setup operation
without changing the jobname of the dependent computer operation.
In this case, do not use the OPNO() or WSNAME() keywords for applications
that contain job setup operations.
Examples:
- CHGJOB APPL(TEST01) OLDJ(job11111) NEWJ(job22222)
- Changes the jobname to all the operations with JOB11111
- CHGJOB APPL(TEST01) IAD(&OYMD1), NEWJ(job22222) OP(20)
- Changes the jobname to operation 20
- CHGJOB APPL(TEST01) IA(=) NEWJ(job22222) WS(CPU1)
- Changes the jobname to all the operations at the workstation CPU1
- CHGJOB APPL(TEST01) IAD(970708) IAT(1800), NEWJ(job22222) WS(CPU1) OP(20)
- Changes the jobname to operation 20 at the workstation CPU1
The CHGJOB instruction returns one of the following return codes:
- RESULT = 0
- Occurrence modified.
- RESULT = 4
- Occurrence or operations not found in the current plan.
- RESULT = 8
- Invalid instruction or PIF problem. Refer to the error messages.