Change Job Exit Point


Required Parameters:


Exit Point Name: QIBM_QWT_CHGJOB

Exit Point Format Name: CHGJ0100

The Change Job exit program is called from the job using the Change Job Command (CHGJOB) or API (QWTCHGJB)when changing a job on a job queue.


Authorities and Locks

A user must have all object (*ALLOBJ) and security administrator (*SECADM ) special authorities to add exit programs to the registration facility or to remove exit programs from the registration facility.


Required Parameters

Exit program data
INPUT; CHAR(*)

The data that is passed to the exit program. The data contains identification for the job being changed and the job attributes that are being changed. For details, see CHGJ0100 Format.

Length of exit program data
INPUT; BINARY(4)

The length of the data sent to the exit program.

CHGJ0100 Format

The following table describes the information that is located in the Exit program data parameter for the CHGJ0100 format. For detailed descriptions of the fields, see Field Descriptions. Also see the Change Job (QWTCHGJB) API for additional information.




Field Descriptions

See Work Management API Attribute Descriptions (WMAttrDesc) for field names that are not documented below.

Exit information length..The length of information returned in the CHGJ0100 format.

Internal job identifier. An input value to other APIs to increase the speed of locating the job on the system. Only IBM i APIs use this identifier. The identifier is not valid following an initial program load (IPL). If you attempt to use it after an IPL, an exception occurs.

Job name.The name of the job that is being changed.

Job number.The number of the job that is being changed.

Job user.The user profile of the job that is being changed.

Job queue.The name of the job queue where the job being changed is located.

Job queue library.The name of the library where the job queue is located.

Job queue library ASP device name. The name of the auxiliary storage pool (ASP) device description for the ASP containing the library for the job queue. This field will contain hex zeros when there is no job queue associated with the job. This field will contain a name or one of the following special values:

Key.The key for the job attribute that was changed by the Change Job (QWTCHGJB) API. See valid keys for the list of valid keys.

Key data. The data for the job attribute that was changed by the Change Job (QWTCHGJB) API.

Key data length. The length of the data for the key data field.

Key data type. The type of dat contained by the key data field. The possible values returned in this field are:

Length of key record.

Number of variable length key records.

Offset to variable length key records.

Reserved. An ignored field.

Time-stamp job entered system. The date and time the job entered the system. This is in system time-stamp format.


Program Data

When you register the exit program, the following is required for the program data.



Field Descriptions

Job queue. The exit program will be called when a job is changed on this job queue. The following special value is supported:

Job queue library. The name of the library that contains the job queue. The following special value is supported:

Usage Notes

  1. The exit program is called from the job executing the CHGJOB command or API.
  2. When the job queue is being changed for a job, the exit program is called when the program data in the registration facility matches the original job queue.
  3. The exit program is called after the requested job attributes have been changed.
  4. The information is retrieved from the registration facility and saved the first time the exit is used in a job. Changes to the job queues registered may not be reflected until a new job starts.
  5. The exit program is not called from system jobs.
  6. Exceptions signaled to the caller of the exit program will not cause the Change Job to fail.
  7. The exit program cannot call the Change job command or API, as this will create a recursive loop condition.
  8. See the Command Analyzer Retrieve and Command Analyzer Change exit points and the Job Notification exit point for other related exit points.

Exit program introduced: 7.4

[ Back to top | Work Management APIs | APIs by category ]