Retrieve Identity of Last Spooled File Created (QSPRILSP) API


  Required Parameter Group:


  Default Public Authority: *USE

  Threadsafe: Yes

The Retrieve Identity of Last Spooled File Created (QSPRILSP) API returns the complete spooled file identity of the last spooled file created for the current job or thread.

Authorities and Locks

None

Required Parameter Group

Receiver variable
OUTPUT; CHAR(*)

The receiver variable that receives the information requested. You can specify the size of the area to be smaller than the format requested as long as you specify the length parameter correctly. As a result, the API returns only the data that the area can hold.

Length of receiver variable
INPUT; BINARY(4)

The length of the receiver variable provided. The length of receiver variable parameter may be specified up to the size of the receiver variable specified in the user program. If the length of receiver variable parameter specified is larger than the allocated size of the receiver variable specified in the user program, the results are not predictable. The minimum length is 8 bytes.

Format name
INPUT; CHAR(8)

The format of the spooled file identity being returned. The valid format is SPRL0100.

Error code
I/O; CHAR(*)

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


Format of Receiver Variable

The following table describes the order and format of the data that is returned in the receiver variable.

SPRL0100 Format



Field Descriptions

Bytes available. The number of bytes of data available to be returned. All available data is returned if enough space is provided.

Bytes returned. The number of bytes of data returned.

Job name. The name of the job that owns the spooled file.

Job number. The number of the job that owns the spooled file.

Job system name. The name of the system where the job that created the spooled file ran.

Spooled file create date. The date, based on local job time, that the spooled file was created on the system. The date is in the CYYMMDD format as follows:

Spooled file create time The time, in local job time, that the spooled file was created on the system. The time is in the HHMMSS format where:

Spooled file name. The name of the last spooled file created by the current job or thread.

Spooled file number. The number of the last spooled file created by the current job or thread.

User name. The name of the user who owns the last spooled file created by the current job or thread.

Error Messages



API introduced: V5R2

[ Back to top | Print APIs | APIs by category ]