Description:
Truncate data at the specified position and reject all the remaining part if any.
Syntax:
floor(numberExp, {nExp})
Note:
The function truncates data numberExp at the specified position nExp and rejects all the remaining part if any.
Parameter:
numberExp |
Data to be truncated |
nExp |
An integer specifying the position from which data is to be truncated; taken as 0 when it is omitted >0: Move the decimal point to the right for nExp places <0: Move the decimal point to the left for nExp places =0: Indicate the current decimal place |
Return value:
Numeric type
Example:
floor(3451231.234,0) |
3451231.0 |
floor(3451231.234,-1) |
3451230.0 |
floor(3451231.234,-2) |
3451200.0 |
floor(3451231.234,1) |
3451231.2 |
floor(3451231.234,2) |
3451231.23 |
Related function: