Purpose |
Round a numeric value to a specified number of decimal places. |
Syntax |
x = ROUND(numeric_expression, n) |
Remarks |
n is an
Rounding is done according to the "banker's rounding" principle: if the fractional digit being rounded off is exactly five, with no trailing digits, the number is rounded to the nearest even number. This provides better results, on average, than the simple "round up at five" approach. A% = ROUND(0.5, 0) ' 0 A% = ROUND(1.5, 0) ' 2 A% = ROUND(2.5, 0) ' 2 A% = ROUND(2.51, 0) ' 3 |
See also |