Mathematical Functions (Transact-SQL)

Mathematical Functions (Transact-SQL)

 

APPLIES TO: Mathematical Functions (Transact-SQL)SQL Server Mathematical Functions (Transact-SQL)Azure SQL Database Mathematical Functions (Transact-SQL)Azure SQL Data Warehouse Mathematical Functions (Transact-SQL)Parallel Data Warehouse

The following scalar functions perform a calculation, usually based on input values that are provided as arguments, and return a numeric value:

     
ABS DEGREES RAND
ACOS EXP ROUND
ASIN FLOOR SIGN
ATAN LOG SIN
ATN2 LOG10 SQRT
CEILING PI SQUARE
COS POWER TAN
COT RADIANS  

 Note

Arithmetic functions, such as ABS, CEILING, DEGREES, FLOOR, POWER, RADIANS, and SIGN, return a value having the same data type as the input value. Trigonometric and other functions, including EXP, LOG, LOG10, SQUARE, and SQRT, cast their input values to float and return a float value.

All mathematical functions, except for RAND, are deterministic functions. This means they return the same results each time they are called with a specific set of input values. RAND is deterministic only when a seed parameter is specified. For more information about function determinism, see Deterministic and Nondeterministic Functions.

上一篇:第44月第20天 The dispatch_queue_set_specific() and dispatch_get_specific() functions take a "void *


下一篇:利用Azure Functions和k8s构建Serverless计算平台