Generating a report of COBOL programs
Use ddname IGZPROUT at the run step of your JCL to generate a report of
COBOL programs that are compiled with Enterprise COBOL 5 or later releases.
About this task
The report provides details including the ID, Program Name, Compiler Version, Compilation Time
and Date, and SERVICE information. For details about the SERVICE option, see SERVICE.
COBOL
ACTIVE PROGRAMS heading if they are active at program termination. Details of dynamically
called programs that have been cancelled are printed separately under the CANCELLED
PROGRAMS heading. Statically called programs and those called via DLL linkage cannot be
cancelled. Therefore, the report does not include these programs under the CANCELLED
PROGRAMS heading when attempted. For details about the CANCEL statement,
see CANCEL
statement in the Enterprise COBOL for z/OS® Language Reference. For details about DLL programs, see Using DLL linkage and dynamic calls together.COBOL ACTIVE PROGRAMS or CANCELLED
PROGRAMS headings, based on its status at termination. For example, if a program is
dynamically called again after cancellation at termination, it will appear under the COBOL
ACTIVE PROGRAMS heading. If a program is subsequently cancelled again at termination, it
will appear under the CANCELLED PROGRAMS heading.Each dynamic, static, or DLL program is assigned a unique 6-digit ID. The character ‘M’ precedes the 6-digit ID to identify the main program. In the generated report, program names are limited to 8 characters and service strings are limited to 10 characters. If either the program name or service string exceeds these limits, an asterisk will precede it. A separate section at the end of the report will display the longer program name or service string along with their corresponding ID. For details about program names, see PROGRAM-ID paragraph in the Enterprise COBOL for z/OS Language Reference.
- Programs compiled with IBM Enterprise COBOL for z/OS 4.2 and earlier
- Programs compiled with
LP(64) - Any non-COBOL programs that either call a COBOL program or are called by a COBOL program
IGZPROUT ddname are as
follows:DSORG = PS RECFM = FB LRECL = 80//IGZPROUT DD SYSOUT=*//IGZPROUT DD DSN=dynamic.call.report.dsname,DISP=SHR//IGZPROUT DD DSN=dynamic.call.report.dsname,
// UNIT=SYSDA,SPACE=(TRK,(5,10),RLSE),
// DCB=(DSORG=PS,LRECL=80,RECFM=FB,BLKSIZE=0),
// DISP=(NEW,CATLG,DELETE)
+++++++++++++ BEG OF COBOL 5 AND LATER RELEASES PROGRAM REPORT V02 +++++++++++++
================================================================================
= COBOL ACTIVE PROGRAMS = (1)
================================================================================
ID NAME VERSION DATE/TIME COMPILED SERVICE (2)
------ -------- ------- ------------------- ----------
000001 PROG1 060400 2024/03/20 10:56:40
000002 PROG2 060200 2024/03/20 10:56:40 SERVICE 1
000003 PROG3 060400 2024/03/20 10:56:42 *SERVICE ST
000004 *PROG4LON 060300 2024/03/20 10:56:42
000005 *PROG5THI 060400 2024/03/20 10:56:42 *LONG SERVI
M000006 PROG8 060200 2024/03/20 10:56:42 (3)
================================================================================
= CANCELLED PROGRAMS = (4)
================================================================================
ID NAME VERSION DATE/TIME COMPILED SERVICE
------ -------- ------- ------------------- ----------
000007 PROG6 060300 2024/03/20 10:56:40
000008 PROG9 060400 2024/03/20 10:56:40 *SERVICE ST
================================================================================
= LONG PROGRAM NAME LIST = (5)
================================================================================
ID PROGRAM NAME
------ ----------------------------------------------------------------------
000004 PROG4LONGPROGRAMNAME1
000005 PROG5THISISALONGPROGRAMNAMETHISISALONGPROGRAMNAMETHISISALONGPROGRAMNAM
ETHISISALONGPROGRAMNAMETHISISALONGPROGRAMNAMETHISISALONGPROGRAMNAMETHI
SISALONGPROGRAMNAMET
================================================================================
= LONG SERVICE STRING LIST = (6)
================================================================================
ID SERVICE STRING
------ ----------------------------------------------------------------
000003 SERVICE STRING LONG 1
000005 LONG SERVICE STRING CAN HAVE A MAXIMUM LENGTH OF 64 CHARACTERS!
000008 SERVICE STRING LONG 2
++++++++++++++++++++++++++++ END OF PROGRAM REPORT +++++++++++++++++++++++++++++
- (1)
-
The
COBOL ACTIVE PROGRAMSsection is always displayed by default. - (2)
-
ID: Each program is assigned a unique ID for easy reference throughout the report. In this example,PROG1is assigned theIDof 000001. The total number of programs can be determined by identifying the largestIDvalue, which could be in theCOBOL ACTIVE PROGRAMSorCANCELLED PROGRAMSsection, depending on whether there are cancelled programs.NAME: TheNAMEcolumn shows the COBOLPROGRAM-IDand can display up to 8 characters in theCOBOL ACTIVE PROGRAMSsection. If the program name exceeds 8 characters, an asterisk (*) appears before the name, indicating it is a long name. The full program name is listed separately in theLONG PROGRAM NAME LISTsection with its corresponding ID. For example, program ID 000004 has a name longer than 8 characters. The first 8 characters,PROG4LON, are shown with an asterisk, and the full name is printed in theLONG PROGRAM NAME LISTsection.Note: For dynamic calls, the program-name in thePROGRAM-IDparagraph orENTRYstatement must be identical to the corresponding program object name or program object alias of the program object that contains the program. If thePROGRAM-IDparagraph or theENTRYstatement is not identical to the corresponding program object (PDSE member) name or program object alias of the program object that contains the program, then the report will list the program-name in thePROGRAM-IDparagraph or theENTRYstatement, as opposed to listing the program object (PDSE member) name or the program object alias name.VERSION: Indicates the version of the compiler, represented by an integer in the format VVRRMM, where VV stands for the compiler version number, RR stands for the compiler release number, and MM stands for the compiler modification number. For example, compiler version 6.4.0 is represented as 060400.DATE/TIME COMPILED: Indicates the date and time of the compilation.SERVICE: TheSERVICEcolumn displays theSERVICEstring associated with each program and can show up to 10 characters in theCOBOL ACTIVE PROGRAMSorCANCELLED PROGRAMSsection. If the string exceeds 10 characters, an asterisk (*) appears before it, indicating a longSERVICEstring. The fullSERVICEstring is listed separately in theLONG SERVICE STRING LISTsection with its corresponding ID. For example, program ID 000008, namedPROG8, was cancelled at termination. Since itsSERVICEstring was longer than 10 characters, the first 10 characters are printed in theCANCELLED PROGRAMSsection, and the full string is printed in theLONG SERVICE STRING LISTsection.
- (3)
- The character ‘M’ before the ID value 000006 of
PROG8identifies the main program.PROG8is the caller program that calls other COBOL programs either dynamically, statically, or via DLL linkage. - (4)
- The
CANCELLED PROGRAMSsection is displayed only if there are programs that were dynamically called and then cancelled using the CANCEL statement. - (5)
- The
LONG PROGRAM NAME LISTsection is optionally displayed depending on whether any program names exceed 8 characters. See alsoNAMEin (2).In the
LONG PROGRAM NAME LISTsection, program names are printed with a maximum of 70 characters per line before wrapping to the next line. For example, for program ID 000005 with a 160-character name, the first 70 characters are displayed on the first two lines, and the remaining 20 characters appear on the third line. There is no special character to indicate the name wrapping. - (6)
- The
LONG SERVICE STRING LISTsection is optionally displayed depending on whether anySERVICEstrings exceed 10 characters. See alsoSERVICEin (2).
Making dynamic calls