The ENTRY statement establishes an alternate entry point into a COBOL called subprogram.
The ENTRY statement cannot be used in:
When a CALL statement that specifies the alternate entry point is executed in a calling program, control is transferred to the next executable statement following the ENTRY statement.
Format >>-ENTRY--literal-1---------------------------------------------> >--+--------------------------------------------------------+---> | .---------------------------------------------. | | | .--------------. | | | V V | | | '-USING------+-------------------+----identifier-1-+---+-' +-+----+--REFERENCE-+ | '-BY-' | '-+----+--VALUE-----' '-BY-' >--.-----------------------------------------------------------><
Must not match the program-ID or any other ENTRY literal in this program.
Must not be a figurative constant.
Execution of the called program begins at the first executable statement following the ENTRY statement whose literal corresponds to the literal or identifier specified in the CALL statement.
The entry point name on the ENTRY statement can be affected by the PGMNAME compiler option. For details, see the Enterprise COBOL Programming Guide.