ᑍ create and manipulate a ᑍDTAQ.
ᑍ
ᑍ Header Files Included: QUSEC - Error Code Parameter
ᑍ QCAPCMD - Process Command API
ᑍ
ᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍ
ᑍ
ᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍᑍ
PROGRAM-ID. DQUEUEX.
ENVIRONMENT DIVISION.
CONFIGURATION SECTION.
SOURCE-COMPUTER. IBM-AS4.
OBJECT-COMPUTER. IBM-AS4.
INPUT-OUTPUT SECTION.
FILE-CONTROL.
SELECT LISTING ASSIGN TO PRINTER-QPRINT
ORGANIZATION IS SEQUENTIAL.
DATA DIVISION.
FILE SECTION.
FD LISTING RECORD CONTAINS 132 CHARACTERS
LABEL RECORDS ARE STANDARD
DATA RECORD IS LIST-LINE.
1 LIST-LINE PIC X(132).
WORKING-STORAGE SECTION.
ᑍ
ᑍ Error Code parameter include
ᑍ
COPY QUSEC OF QSYSINC-QLBLSRC.
ᑍ
ᑍ Process Command API Include
ᑍ
COPY QCAPCMD OF QSYSINC-QLBLSRC.
ᑍ
ᑍ Command strings
ᑍ
1 CRTLIB PIC X(5) VALUE "CRTLIB QUEUELIB".
1 DLTLIB PIC X(5) VALUE "DLTLIB QUEUELIB".
1 CRTDQ PIC X(5)
VALUE "CRTDTAQ QUEUELIB/EXAMPLEQ MAXLEN(1)".
1 DLTDQ PIC X(5) VALUE "DLTDTAQ QUEUELIB/EXAMPLEQ".
ᑍ
ᑍ Error message text
ᑍ
1 BAD-NEWS.
5 TEXT1 PIC X(14) VALUE "Failed in API ".
5 API-NAME PIC X(1) VALUE "QCAPCMD".
5 TEXT2 PIC X(11) VALUE "with error ".
5 EXCEPTION-ID PIC X(7).
ᑍ
ᑍ Miscellaneous elements
ᑍ
1 COMMAND-LENGTH PIC S9(9) VALUE 5 BINARY.
1 RECEIVER PIC X(1).
1 RECEIVER-LENGTH PIC S9(9) VALUE BINARY.
1 OPTIONS-SIZE PIC S9(9) VALUE 2 BINARY.
1 FORMAT-NAME PIC X(8) VALUE "CPOP1".
1 FIRST-ERROR PIC X(1) VALUE "".
1 NAME-OF-QUEUE PIC X(1) VALUE "EXAMPLEQ".
B-166 System API Programming V4R1