How to: |
Available Languages: reporting, Maintain
The INT function returns the integer component of a number.
INT(in_value)
where:
Numeric
Is the value for which the integer component is returned, the name of a field that contains the value, or an expression that returns the value. If you supply an expression, use parentheses as needed to ensure the correct order of evaluation.
INT finds the greatest integer in the DED_AMT field and stores it in INT_DED_AMT:
TABLE FILE EMPLOYEE SUM DED_AMT AND COMPUTE INT_DED_AMT/I9 = INT(DED_AMT);BY LAST_NAME BY FIRST_NAME WHERE (DEPARTMENT EQ 'MIS') AND (PAY_DATE EQ 820730); END
The output is:
LAST_NAME FIRST_NAME DED_AMT INT_DED_AMT --------- ---------- ------- ----------- BLACKWOOD ROSEMARIE $1,261.40 1261 CROSS BARBARA $1,668.69 1668 GREENSPAN MARY $127.50 127 JONES DIANE $725.34 725 SMITH MARY $334.10 334