Binary operator precedence

When a PromQL query is evaluated, the order in which binary operators are applied is dictated by the operator precedence. The following table shows the precedence order, from higher to lower:

Precedence Operator Description

1

^ Evaluated right to left, for example, 1 ^ 2 ^ 3 is evaluated as 1 ^ (2 ^ 3)
2 *, /, % Evaluated left to right, for example, 1 / 2 * 3 is evaluated as (1 / 2) * 3
3 +, - Evaluated left to right
4 ==, !=, <=, <, >=, > Evaluated left to right
5 and, unless Evaluated left to right
6 or Evaluated left to right
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.221.13.173