# MySQL POWER() function

## POWER() function

MySQL POWER() returns the value of a number raised to the power of another number. The synonym of POWER() is POW().

This function is useful in -

- POWER() is essential for modeling phenomena involving exponential growth or decay, such as compound interest, population growth, radioactive decay, and more.
- POWER() is a key component in many scientific formulas, especially those that involve exponential relationships.
- In finance, POWER() is crucial for calculating compound interest and determining future values of investments.
- To compute the power of a signal the POWER() is fundamental in telecommunications, audio processing, image processing, and other fields where signal analysis is essential.
- POWER() is utilized in probability and statistics for various calculations, including likelihood ratios, likelihood functions, and power functions in hypothesis testing.
- In thermodynamics and heat transfer, POWER() is applied to model temperature distributions, heat transfer rates, and other phenomena involving exponential relationships.

**Syntax:**

POWER(M,N);

**Arguments:**

Name | Description |
---|---|

M | A number which is the base of the exponentiation. |

N | A number which is the exponent of the exponentiation. |

**Syntax Diagram:**

**MySQL Version: 8.0**

**Pictorial presentation of MySQL POWER() function**

**Example of MySQL POWER() function**

Code:

```
SELECT POWER(3, 2);
```

**Explanation:**

The above MySQL statement returns the value of 3^{2}, i.e. 9.

Output:

mysql> SELECT POWER(3, 2); +-------------+ | POWER(3, 2) | +-------------+ | 9 | +-------------+ 1 row in set (0.00 sec)

**Example : POWER() function with negative value**

Code:

```
SELECT POWER(4,-2);
```

**Explanation:**

The above MySQL statement returns the value of 4^{-2}, i.e. 0.0625.

Output:

mysql> SELECT POWER(4,-2); +-------------+ | POWER(4,-2) | +-------------+ | 0.0625 | +-------------+ 1 row in set (0.00 sec)

**Weekly Trends**- Python Interview Questions and Answers: Comprehensive Guide
- Scala Exercises, Practice, Solution
- Kotlin Exercises practice with solution
- MongoDB Exercises, Practice, Solution
- SQL Exercises, Practice, Solution - JOINS
- Java Basic Programming Exercises
- SQL Subqueries
- Adventureworks Database Exercises
- C# Sharp Basic Exercises
- SQL COUNT() with distinct
- JavaScript String Exercises
- JavaScript HTML Form Validation
- Java Collection Exercises
- SQL COUNT() function
- SQL Inner Join

We are closing our Disqus commenting system for some maintenanace issues. You may write to us at reach[at]yahoo[dot]com or visit us at Facebook