Operators
FQL provides a set of operators for comparing values, combining conditions, performing arithmetic, working with arrays, and controlling evaluation order. Operators are used throughout the language in expressions, filters, projections, and conditions.
Comparison
Comparison operators compare two operands and return a boolean result. They include equality (==, !=), ordering (<, <=, >, >=), containment (IN, NOT IN), pattern matching (LIKE, NOT LIKE), and regular expression matching (=~, !~).
See Comparison Operators.
Logical
Logical operators evaluate expressions according to their truth value. FQL supports && / AND, || / OR, and ! / NOT. The binary operators use short-circuit evaluation and return one of their operands rather than always returning a boolean.
See Logical Operators.
Arithmetic
Arithmetic operators perform operations on numeric operands: addition (+), subtraction (-), multiplication (*), division (/), and modulus (%). Unary plus and minus are also supported.
See Arithmetic Operators.
Range
The range operator (..) produces an array of integer values between two bounds, inclusive.
See Range Operator.
Ternary
The ternary operator provides conditional evaluation. It returns one of two values depending on a boolean condition.
See Ternary Operator.
Array
Array operators work with arrays and nested array structures. They include indexed access ([]), expansion ([*]), flattening ([**]), inline filtering and projection, the question mark operator ([?]), and array comparison operators (ANY, ALL, NONE).
See Array Operators.
Precedence
Operator precedence determines the order in which operators are evaluated. Parentheses can override the default evaluation order.
See Operator Precedence.