MULTIPLY

Basic form

MULTIPLY n1 BY n2.

Effect

Multiplies the contents of n1 by the contents of n2 and places the result in n1.

This is equivalent to: n1 = n1 * n2.

Example

DATA: DAYS_PER_YEAR    TYPE P VALUE 365,
      HOURS_PER_DAY    TYPE F VALUE '24.0',
      MINUTES_PER_YEAR TYPE I VALUE 1.
MULTIPLY MINUTES_PER_YEAR BY DAYS_PER_YEAR.
MULTIPLY MINUTES_PER_YEAR BY HOURS_PER_DAY.
MULTIPLY MINUTES_PER_YEAR BY 60.

MINUTES_PER_YEAR now contains 525600.

Note

The details about conversions and performance given under COMPUTE also apply to MULTIPLY.

Exceptions

Catchable Exceptions

CX_SY_ARITHMETIC_OVERFLOW

CX_SY_CONVERSION_OVERFLOW

Non-Catchable Exceptions

Related

COMPUTE, MULTIPLY-CORRESPONDING

Additional help

Arithmetic Computations