Mathematical Functions in SQL Server

Some commonly used mathematical functions are given below:

List of Mathematical Functions in SQL Server with Syntax

Function Description Syntax
SQRT() Returns the square root of a numeric value. SELECT SQRT(..value..)
PI() Returns the value of pi (3.14159265358979). SELECT PI()
SQUARE() Returns the square of a numeric value. SELECT SQUARE(..value..)
ROUND() Rounds a numeric value to the specified number of decimal places. SELECT ROUND(..value.., number_of_decimal_places)
CEILING() Returns the smallest integer greater than or equal to a numeric value. SELECT CEILING(..value..)
FLOOR() Returns the largest integer less than or equal to a numeric value. SELECT FLOOR(..value..)

SQL Server Mathematical Functions (SQRT, PI, SQUARE, ROUND, CEILING & FLOOR)

SQL Server mathematical functions are used to perform mathematical calculations. These functions are designed to simplify complex calculations and make it easier to analyze and manipulate data.

Here, we will cover the syntax and examples of various mathematical functions like SQRT(), PI(), SQUARE(), and many more

Similar Reads

Mathematical Functions in SQL Server

Some commonly used mathematical functions are given below:...

SQL Server Mathematical Functions Examples

Let’s look at some examples of the mentioned mathematical functions in SQL Server....