Rational Developer for System z
Enterprise COBOL for z/OS, Version 4.1, Programming Guide


Coding COBOL programs to run under CICS

To code a program to run under CICS, code CICS commands in the PROCEDURE DIVISION by using the EXEC CICS command format.

EXEC CICS command-name command-options
END-EXEC

CICS commands have the basic format shown above. Within EXEC commands, use the space as a word separator; do not use a comma or a semicolon.

Restrictions: COBOL class definitions and methods (object-oriented COBOL) cannot be run in a CICS environment. In addition, when you code your programs to run under CICS, do not use the following code:

If you plan to use the separate CICS translator, you must put any REPLACE statements that contain EXEC commands after the PROCEDURE DIVISION header for the program, otherwise the commands will not be translated.

Coding file input and output: You must use CICS commands for most input and output processing. Therefore, do not describe files or code any OPEN, CLOSE, READ, START, REWRITE, WRITE, or DELETE statements. Instead, use CICS commands to retrieve, update, insert, and delete data.

Coding a COBOL program to run above the 16-MB line: Under Enterprise COBOL, the following restrictions apply when you code a COBOL program to run above the 16-MB line:

Displaying the contents of data items: DISPLAY to the system logical output device (SYSOUT, SYSLIST, SYSLST) is supported under CICS. The DISPLAY output is written to the Language Environment message file (transient data queue CESE). DISPLAY . . . UPON CONSOLE and DISPLAY . . . UPON SYSPUNCH, however, are not allowed.

related concepts  
Integrated CICS translator

related references  
CICS SORT application restrictions


Terms of use | Feedback

This information center is powered by Eclipse technology. (http://www.eclipse.org)