Rational Developer for System z
Enterprise COBOL for z/OS, Version 4.1, Language Reference


The procedure division header

The procedure division, if specified, is identified by one of the following headers, depending on whether you are specifying a program, a factory definition, an object definition, or a method definition.

The following is the format for a procedure division header in a program.

Read syntax diagramSkip visual syntax diagram
Format: program procedure division header

>>-PROCEDURE DIVISION------------------------------------------->

>--+-------------------------------------------------------+---->
   |        .--------------------------------------------. |   
   |        |                          .-------------.   | |   
   |        V                          V             |   | |   
   '-USING------+-------------------+----data-name-1-+---+-'   
                +-+----+--REFERENCE-+                          
                | '-BY-'            |                          
                '-+----+--VALUE-----'                          
                  '-BY-'                                       

>--+------------------------+--.-------------------------------><
   '-RETURNING--data-name-2-'      

The following is the format for a procedure division header in a factory paragraph or object paragraph.

Read syntax diagramSkip visual syntax diagram
Format: factory and object procedure division header

>>-PROCEDURE DIVISION.-----------------------------------------><

The following is the format for a procedure division header in a method.

Read syntax diagramSkip visual syntax diagram
Format: method procedure division header

>>-PROCEDURE DIVISION------------------------------------------->

>--+-------------------------------------------+---------------->
   |        .--------------------------------. |   
   |        |                .-------------. | |   
   |        V                V             | | |   
   '-USING----+----+--VALUE----data-name-1-+-+-'   
              '-BY-'                               

>--+------------------------+----------------------------------><
   '-RETURNING--data-name-2-'   


Terms of use | Feedback

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