Truncates a numeric value to a specified length.
Category: | Truncation |
Returned data type: | DOUBLE |
specifies any valid expression that evaluates to a numeric value.
Data type | DOUBLE |
See | <sql-expression> |
FedSQL Expressions |
specifies any valid expression that evaluates to a numeric value.
Range | 3–8 |
Data type | DOUBLE |
See | <sql-expression> |
FedSQL Expressions |
Statements
|
Results
|
---|---|
select trunc(3.1,3); select trunc(3.1,4); select trunc(3.1,5); select trunc(3.1,6); select trunc(3.1,7); select trunc(3.1,8); |
3.099609375 3.0999984741 3.099999994 3.1 3.1 3.1 |