|
abs()
The
Mathematical Function
abs()
returns the absolute value of the parameter "number"
. The return value is of the same datatype and precision as the value of the parameter "number".
Syntax of the Mathematical Function abs()
the parameter "number" of the Mathematical Function abs()
number
The parameter "number" is a place holder for column names, variables
or
"expressions",
which have to be of the datatype
exact numeric,
approximate numeric,
money
In addition, the parameter "number" recognises every other datatype which can be converted with
implicit conversion
into any of the required datatypes.
Example for the Mathematical Function abs()
select abs(-1)
go
-----
1
Returns the absolute value of 1.
See also:
ASE T-SQL - Aggregate Functions, Mathematical Functions, acos(), asin(), atan(), atn2(), ceiling(), cos(), cot(), degrees(), exp(), floor(), log(), log10(), pi(), power(), radians(), rand(), round(), sign(), sin(), sqrt(), tan().
|