ALTER Statement - COBOL

The ALTER statement modifies a predetermined sequence of operations.

ALTER Statement

procedure-name-1 is the name of a paragraph that contains a single sentence consisting of a GO TO statement without the DEPENDING phrase.

procedure-name-2 is the name of a paragraph or section in the Procedure Division.

Execution of the ALTER statement modifies the GO TO statement in the paragraph named procedure-name-1, so that subsequent executions of the modified GO TO statements cause transfer of control to procedure-name-2. Modified GO TO statements in independent segments may, under some circumstances, be returned to their initial states; see the rules for segmentation in Chapter Procedure Division.

A GO TO statement in a section whose segment-number is greater than or equal to 50 must not be referred to by an ALTER statement in a section with a different segment-number.

ALTER Statement Examples

All rights reserved © 2020 Wisdom IT Services India Pvt. Ltd Protection Status

COBOL Topics