ABS
Calculates the absolute value of a number <value>
, displaying the number’s distance from 0
.
Syntax
ABS(<value>)
Parameters
Parameter | Description | Supported input types |
---|---|---|
<numeric_type> | The number that the absolute value function is applied to. | Any NUMERIC type |
Return Type
NUMERIC
Example
The following example returns the absolute value of -200.5
:
SELECT ABS(-200.50) as result;
result (DOUBLE) |
---|
200.5 |