%FLOAT (Convert to Floating Format)
%FLOAT(numeric or character expression)
%FLOAT converts the value of the expression to float format. This built-in function may only be used in expressions.
If the parameter is a character expression, the following
rules apply:
- The sign is optional. It can be '+' or '-'. It must precede the numeric data.
- The decimal point is optional. It can be either a period or a comma.
- The exponent is optional. It can be either 'E' or 'e'. The sign for the exponent is optional. It must precede the numeric part of the exponent.
- Blanks are allowed anywhere in the data. For example, ' + 3 , 5 E 9' is a valid parameter.
- If invalid numeric data is found, an exception occurs with status code 105.
For more information, see Conversion Operations or Built-in Functions.