# PostgreSQL POWER() function

## POWER() function

The PostgreSQL power() function is used to return the value of one number raised to the power of another number, provided in the argument.

##### Uses of POWER() Function
• Exponential Calculations: To perform calculations involving exponentiation.

• Mathematical Operations: Useful in various mathematical formulas that require raising a number to a power.

• Scientific Research: Employed in scientific computations involving growth rates, decay, and other exponential models.

• Financial Modeling: To calculate compound interest and other financial scenarios requiring exponentiation.

• Engineering Applications: Important in engineering calculations involving power and exponential growth.

Syntax:

```power()
```

PostgreSQL Version: 9.3

Pictorial presentation of PostgreSQL POWER() function

Example 1: PostgreSQL POWER() function :

Code:

``````SELECT POWER(7.0,3) AS "7 raised to the power of 3";
```
```

Sample Output:

``` 7 raised to the power of 3
----------------------------
343.0000000000000000
(1 row)
```

Example 2: PostgreSQL POWER() function

Code:

``````SELECT POWER(7,3) AS "7 raised to the power of 3";
```
```

Sample Output:

``` 7 raised to the power of 3
----------------------------
343
(1 row)
```

Previous: PI function