Pathway/iTS SCREEN COBOL Reference Manual (H06.10+, J06.03+)
Procedure Division
HP NonStop Pathway/iTS SCREEN COBOL Reference Manual—426750-003
6-79
PERFORM Statements
multiplier
is the identifier of an elementary numeric data item. The result of the multiply
operation is stored as the new value of
multiplier
. The sum of the number of
digits in
value
and
multiplier
must not exceed 18.
MULTIPLY GIVING Statement
The MULTIPLY GIVING statement multiplies two numeric data items and stores the
product in one or more other data items.
value
is the multiplicand, which is a numeric literal or an elementary numeric data item.
multiplier
is a numeric literal or the identifier of an elementary numeric data item. The sum of
the number of digits of
value
and
multiplier
must not exceed 18.
result
is the identifier of an elementary numeric data item into which the product is stored.
PERFORM Statements
The PERFORM statements run one or more procedures in a program. When a single
paragraph or section name is specified, control passes to the first statement of the
paragraph or section; when execution of the paragraph or section completes, control
passes to the PERFORM statement. If a group of paragraphs or procedures is
specified, control passes to the first statement of the first paragraph or section; when
execution of the last paragraph or section completes, control returns to the PERFORM
statement.
The forms of the PERFORM statement are:
PERFORM
PERFORM TIMES
PERFORM UNTIL
PERFORM VARYING
PERFORM ONE
In each of these forms, two parameters,
proc-1
and
proc-2
, appear.
Proc-1
and
proc-2
have no special relationship; they represent a consecutive sequence of
operations to be run beginning at
proc-1
and ending with the execution of
proc-2
.
GO TO and PERFORM statements can occur within the range of
proc-1
and
proc-
2
. If two or more logical paths lead to the return point,
proc-2
could be a paragraph
consisting of an EXIT statement, to which all of these paths must lead.
MULTIPLY
value
BY
multiplier
GIVING {
result
} ,...










