INSERT request

The INSERT request writes a new record or record segment to an HCL Workload Automation for Z database or data set. This can be done in several ways:

  • To insert new application descriptions, operator instructions, JCL records, new all workstations closed, calendar, ETT, period, special resource or workstation record, your program must provide the complete record to be inserted in the data area. Arguments are not used.
  • To insert a new application occurrence into the current plan, you can:
    • Provide a complete application description record in the data area. This is then converted by HCL Workload Automation for Z into a current plan occurrence. Here, the arguments can be used to provide the input arrival and deadline date and time.

      Or

    • Select an existing application description from the database to be added as an occurrence into the current plan. Here, the arguments are used to identify the existing application description from which the occurrence will be created. The arguments can also specify occurrence-related information such as input arrival time and deadline time. The data area is not used.
    When inserting an application occurrence into the long-term plan, the name of the application description must be supplied through the argument parameters. You cannot supply an application description through the data area. The data area pointer address must be set to zero before your program call.

    When inserting a new occurrence using either of the previous methods, 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 current plan. If resolution of external dependencies is required, the OPTIONS request must be used to specify this.

  • To insert the extended name of an operation you must use the MODIFY request. For details, see MODIFY CPEXT.
  • To insert new information into an existing LTP or current plan occurrence, you use the arguments to provide all the necessary information. For example, you can insert a new operation into an existing current plan occurrence. But the actual occurrence to which the information is to be added must have been identified by a previous MODIFY or INSERT request. Similarly, you can insert new information for an existing current plan operation, provided that the operation has been identified. This means you must first use a MODIFY request to identify the occurrence and then use a MODIFY request to identify the operation, before inserting a predecessor (CPPRE), successor (CPSUC), or special resource (CPSR).

    When identified, the program interface maintains a current occurrence and current operation.

    If you want to insert a new interval into a current plan workstation you must first identify the workstation with a MODIFY CPWS request.

    The arguments are used to specify all required information. The data area is not used.

The INSERT request can be used to modify information in the current plan. All requests that cause a modification of the current plan require a later EXECUTE request for the modification to take effect.