Explain EXP() Function in SQL?

EXP() function :

This function in SQL Server is used to return a value which is e raised to the nth power, where n is a specified number. Here “e” is a mathematical constant and the base of natural logarithms whose value is 2.7182818 and n is the input number taken as the parameter of the function.

Features :

This function is used to find a value which is e raised to the nth power.

Here the value n, is taken as the parameter of the function.

Here “e” is a mathematical constant and the base of natural logarithms whose value is “2.7182818”.

This function use the formula “(e)n = Returned value“.

Syntax :

SELECT EXP(number);

Parameter :

This method accepts a parameter as given below:

  • number: Specified power number.

Returns :

It returns a value which is “e” raised to the nth power, where n is a specified number.

Example:

Getting value 1.0 which is “e” raised to the 0th power.

SELECT EXP(0);

Output :

1.0