Display Messages
System: GENSYS9
Queue . . . . . : QPGMR Program . . . . : ᑍDSPMSG
Library . . . : QUSRSYS Library . . . :
Severity . . . : Delivery . . . : ᑍHOLD
Type reply (if required), press Enter.
From . . . : SMITH 7/23/94 1:56:13
Program failed with message ID CPF981
Then run another error condition. For this error condition, you should assume that
the XYZ library does not exist. Use the following call statement:
CALL JOBDAPI (QPGMR XYZ)
The output is similar to the following:
Display Messages
System: GENSYS9
Queue . . . . . : QPGMR Program . . . . : ᑍDSPMSG
Library . . . : QUSRSYS Library . . . :
Severity . . . : Delivery . . . : ᑍHOLD
Type reply (if required), press Enter.
From . . . : SMITH 7/23/94 1:56:13
Program failed with message ID CPF981
You should see that the CPF9810 message (Library not found) was issued. An
advantage of the error return variable is that it can contain other information such
as message data. The following are the changes needed to return a 200-byte error
code structure:
Iᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍ
Iᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍ
Iᑍ
IᑍProgram Name: JOBDAPI
Iᑍ
IᑍLanguage: OPM RPG
Iᑍ
IᑍDescriptive Name: Get Job Description
Iᑍ
IᑍDescription: This sample program shows the incorrect
Iᑍ way of using the offset in a user space in RPG.
Iᑍ
IᑍHeader Files Included: QUSEC - Error Code Parameter
Iᑍ (Copied into Program)
Iᑍ QWDRJOBD - Retrieve Job Description API
Iᑍ
Iᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍ
Iᑍ Error Code Parameter Include for the APIs
Iᑍ
Iᑍ The following QUSEC include is copied into this program
Iᑍ so that the variable-length field can be defined as
Iᑍ fixed length.
Iᑍ
Iᑍᑍᑍ START HEADER FILE SPECIFICATIONS ᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍ
Iᑍ
IᑍHeader File Name: H/QUSEC
Iᑍ
IᑍDescriptive Name: Error Code Parameter.
Iᑍ
Iᑍ5763-SS1 (C) Copyright IBM Corp. 1994,1994
IᑍAll rights reserved.
IᑍUS Government Users Restricted Rights -
IᑍUse, duplication or disclosure restricted
Iᑍby GSA ADP Schedule Contract with IBM Corp.
Chapter 3. Common Information across APIs—Basic (OPM) Example 3-15