The ABS function returns the absolute value of column.
This function returns the same datatype as the passed parameter.
ABS( numeric_expression )
Required. Any expression that returns a numeric-class datatype.
> select longitude, abs(longitude) from countries; LONGITUDE ABS(LONGITUDE) -------------------------------- -------------------------------- -176.199997 176.199997 -175.000000 175.000000 -172.330002 172.330002 -171.750000 171.750000 -170.699997 170.699997 -170.000000 170.000000 -169.860001 169.860001
See also: