Skip to content

Latest commit

 

History

History
56 lines (49 loc) · 2.55 KB

mathematical-functions-transact-sql.md

File metadata and controls

56 lines (49 loc) · 2.55 KB
title description author ms.author ms.reviewer ms.date ms.service ms.subservice ms.topic helpviewer_keywords dev_langs monikerRange
Mathematical Functions (Transact-SQL)
Mathematical Transact-SQL functions in the SQL Server Database Engine.
markingmyname
maghan
randolphwest
12/16/2024
sql
t-sql
reference
calculations [SQL Server]
mathematical functions [SQL Server]
functions [SQL Server], mathematical
TSQL
=azuresqldb-current || =azuresqldb-mi-current || >=sql-server-2016 || >=sql-server-linux-2017 || =azuresqledge-current || =azure-sqldw-latest || >=aps-pdw-2016 || =fabric

Mathematical functions (Transact-SQL)

[!INCLUDE sql-asdb-asdbmi-asa-pdw-fabricse-fabricdw]

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

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're 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.

Related content