Skip to main content

POWER

Returns the value of the specified expression to the specified power.

Syntax​

POWER ( float_expression , y ) 

Arguments​

float_expression
Is an expression of type float or of a type that can be implicitly converted to float.

y Is the power to which to raise float_expression. y can be an expression of the exact numeric or approximate numeric data type category.

Return Type​

Returns values of type FLOAT64.

Examples​

Examples in this section use the example blockchain.

This example returns the values of integer raised to the second power.

SELECT POWER(integer, 2) FROM example;

Response:

POWER(integer, 2) [FLOAT64]
1
0
1
4