INSERT – Add objects into the plan
In Workload Automation Programming Language, use the INSERT
request to add occurrences to the Current Plan and Long-Term Plan. The PIF facility to update the
database is handled by Batch Loader within Workload Automation Programming Language.
INSERT <resource> <arguments> ALIAS(<newname>)
When inserting a new occurrence, the input arrival date and time and deadline date and time can be provided in the arguments. If the input arrival is not provided when inserting a current plan occurrence, the current date and time is used (that is, the date and time at which the occurrence is inserted). However, if an occurrence already exists with this application ID and input arrival date and time, the next available minute in which no occurrence of this application exists will be used. You must supply an input arrival date and time if you are inserting an occurrence in the LTP.
If arguments are not provided for the deadline, these defaults are observed by HCL Workload Automation for Z:
- If the occurrence is being added to the current plan and the input arrival is provided, the deadline from the first run cycle is used if a run cycle exists. If there are no run cycles or the input arrival is not provided, the deadline is set to the input arrival time plus 8 hours.
- When the occurrence is being added to the long-term plan, the deadline is set to the input arrival plus 8 hours.
By default, external dependencies of the occurrence are not resolved
when it is added to the LTP or CP. If resolution of external dependencies
is required, an OPTIONS LTDEPR
or CPDEPR
request
must be used to specify this.
- To insert the extended name of an operation, use the
MODIFY
request. - To insert new information into an existing LTP or CP occurrence,
specify the required arguments. For example, you can insert a new
operation into an existing current plan occurrence, but you must have
first identified the actual occurrence to which the information is
to be added with a previous
MODIFY
orINSERT
request. Similarly, you can insert new information for an existing current plan operation only if you first identified the operation. This means that you must first use aMODIFY
request to identify the occurrence, then you use aMODIFY
request to identify the operation, before inserting a predecessor (CPPRE), successor (CPSUC), or special resource (CPSR).When identified, Workload Automation Programming Language maintains a current occurrence and current operation.
To insert a new interval into a current plan workstation, first identify the workstation with a
MODIFY CPWS
request.
If the INSERT
request was used to modify
information in the current plan, a later EXECUTE
request
must be made for the modification to actually take effect; Workload Automation Programming Language does
this for you automatically if you set OPTIONS EXECUTE(AUTO)
(this
is the default).
- 0
- The request was successful.
- 4
- One or more of the dependencies, specified by the application
description of the
INSERT LTOC
request, was not set up because no applicable predecessor occurrence exists. This return code could also result from anINSERT
request for any of LTPRE, CPOP, CPOC, CPPRE, and CPSR, if the dependency was not set up. - 8
- The request was not successful. An error message is issued to the message log data set.