Find EDRS Job (QxdaFindEDRSJob) API


  Required Parameter Group:


  Service Program: QXDAEDRS

  Default Public Authority: *USE

  Threadsafe: Conditional; see Usage Notes

The Find EDRS Job (QxdaFindEDRSJob) API is used to find all jobs with user-defined data associated with the Connect to EDRS Server (QxdaConnectEDRS) API that matches the data passed to this API.


Authorities and Locks

None.


Required Parameter Group

Connection handle
INPUT; BINARY(4)

The handle number of the connection in which to find jobs. The connection handle must have been generated by the Connect to EDRS Server (QxdaConnectEDRS) API in the current job and activation group.

Job-associated user data
INPUT; CHAR(*)

User data that also was passed to the Connect to EDRS Server (QxdaConnectEDRS) API. This may be the complete user data or only a part of it. If it is only part, it must be the beginning of the user data string.

Length of job-associated user data
INPUT; BINARY(4)

The length of the user data to compare.

Receiver variable
OUTPUT; CHAR(*)

Space for the job information to be returned. This information is returned as an array of QJBI0100 structures, one for each job found. For the format of each array element, see QJBI0100 Format.

Length of receiver variable
INPUT; BINARY(4)

Length (in bytes) of the receiver variable provided to return information about the jobs found.

Receiver variable format
INPUT; CHAR(8)

The format of the structure in which to return information about the jobs found. The possible value is:


Number of jobs found
OUTPUT; BINARY(4)

The number of jobs found with associated user data that matches the user data passed in. This is the total number found, even if the information for all the jobs cannot fit in the space provided.

Number of jobs returned
OUTPUT; BINARY(4)

The actual number of jobs for which information was returned.

Error code
I/O; CHAR(*)

The structure in which to return error information. For the format of the structure, see Error code parameter.


QJBI0100 Format

The following table shows the structure of the QJBI0100 format. For more details about the fields in this table, see Field Descriptions.



Field Descriptions

Internal job identifier. The internal job identifier. This value is sent to other APIs to speed the process of locating the job on the system.

Job name. The name of the job found.

Job number. The number of the job found.

Job user name. The name of the initial user of the job found.

Process ID. The process ID (PID) of the job found.

Reserved. Reserved field; it must be initialized to 0x00.


Usage Notes

This function may be called from the initial thread of a job only.


Error Messages



API introduced: V4R4

[ Back to top | Database and File APIs | APIs by category ]