Exponentiation (**)

The ** operator calculates an exponentiation.


num-expr ** int-expr
  1. num-expr is a numeric expression (real number).
  2. int-expr is the exponent, as a whole number.


The ** operator returns a value calculated by raising the left-hand operand to a power corresponding to the integer part of the right-hand operand.
 n ** e   =   n * n * n ... (e times)

If the right operand (the exponent) is a number with a decimal part, it is rounded to a whole integer before computing the exponentiation.

If one of the operands is NULL, the arithmetic expression evaluates to NULL.

Tip: The ** operator takes an integer as exponent. If you need to raise a number to an exponent that is a real number, use the fgl_decimal_power() utility function.


  DISPLAY 2 ** 8
  DISPLAY 10 ** 4