Round
The Round function rounds a number to the specified number of decimal places.
Definition
Round(valor, [decimales])参数
| 名称 | 说明 | Data type |
|---|---|---|
| valor | Value to be rounded | numeric |
| decimales | Optional parameter indicating how many decimal places to use for rounding. If not specified, rounding is done without decimals. | numeric |
示例
Rounding without decimals
In this example, we will round a given value, removing all decimals:
Round(25.65)The result is 26 (numeric).
Rounding to one decimal place
In this example, we will round a given value, leaving one decimal place:
Round(25.66, 1)The result is 25.7 (numeric).
更多信息
更多信息 about number rounding can be found on Wikipedia.