power

Generic Description

Is the pow alias that raises a numeric base to a numeric exponent. It is documented separately because numeric transforms change ranking, thresholds, and buckets in ways planner tools must not guess.

Simple example:

RETURN power(2.0, 3.0) AS value

Consumer-Level Explanation

Use it when SQL-style spelling is clearer in analytics-oriented Cypher. Prefer this function when the transformation is a deliberate part of the model or report, and name the derived value in a WITH stage when it will be reused.

More Detailed Explanation

power is scalar math, so it is evaluated per row after graph patterns, procedure output, or map projections have produced values. Keep it close to the query when thresholds, ranking, and derived fields need to be auditable and reproducible.

Advanced Example

This example applies power to a named score component after matching graph data, making the derived metric reviewable before ordering.

MATCH (d:Document)
WITH d, properties(d).prize AS priority
RETURN d.title AS document,
       power(priority, 2.0) AS squared_priority
ORDER BY squared_priority DESC

Real Use Cases

Real Limitations And Tradeoffs