Limits on Numbers
There are upper and lower limits on the absolute values of numbers.
These limits apply regardless of the setting of NUMERIC DIGITS or NUMERIC FORM.
If a string that represents a number exceeds one of the limits, it
is treated as non-numeric (data type CHAR):
- A
number is within the upper limit if the following conditions
are true:
- The exponential part does not exceed +999999999. Leading zeros in the exponent are ignored.
- The absolute value of the number does not exceed 9E+999999999.
Examples:- 0.1E1000000000 is not numeric, because the exponent is too large.
- 9.1E+999999999 is not numeric, because the value is too large. If this number is the result of an arithmetic operation, an OVERFLOW occurs and the SYNTAX condition is raised.
- A
number exceeds the lower limit if the following is true for
any operand or for the result: exponent - number of fractional digits in the mantissa < -999999999That is: the difference between the exponent and the number of fractional digits in the mantissa is less than -999999999.
Note that trailing zeros in the fractional part of the mantissa are significant in REXX.
For example, 1.23E-999999998 causes an UNDERFLOW error and raises the SYNTAX condition because -999999998 - 2 is less than -999999999. (The exponent relative to the trailing digit of the mantissa would be -1000000000.)