Open topic with navigation
WTSupported in traditional Synergy on Windows
WNSupported in Synergy .NET on Windows
USupported on UNIX
VSupported on OpenVMS
whole_num = %ROUND(expression)
The nearest whole-number value of a numeric expression. The result has the same numeric data type as expression. (n)
The numeric expression to round. (n)
%ROUND rounds a numeric expression to the nearest whole number.
%ROUND follows normal rounding rules: fractional values less than .5 are rounded down, while fractional values of .5 and above are always rounded up. The fractional precision in the result is the same as the fractional precision in expression, and it is filled with zeros.
The difference between %RND and %ROUND is that with implied-decimal arguments, %RND returns a result with no fractional precision, and %ROUND returns a result with the same fractional precision as expression.
The following example returns a value of 35.00.