Operators Overview
- reference
Operators perform a specific operation on the input values or expressions.
SQL++ provides a full set of operators that you can use within its statements. Here are the categories of SQL++ operators:
-
Arithmetic Operators to perform basic mathematical operations (such as addition, subtraction, multiplication, and divisions) on numbers.
-
Collection Operators to evaluate expressions on collections or objects.
-
Comparison Operators to compare two expressions.
-
Conditional Operators to evaluate conditional logic in an expression.
-
Construction Operators to construct arrays and objects.
-
Logical Operators to combine operators using Boolean logic.
-
Nested Operators and Expressions to access nested elements and embedded arrays.
-
Sequence Operators to access values in a sequence.
-
String Operators to concatenate two expressions.
Operator Precedence
SQL++ supports the use of parentheses to group operators and expressions. Expressions enclosed in parentheses are evaluated first.
The following table shows operator precedence level. An operator at a higher level is evaluated before an operator at a lower level.
Evaluation Order | Operator |
---|---|
1 |
|
2 |
|
3 |
|
4 |
|
5 |
|
6 |
|
7 |
|
8 |
|
9 |
|
10 |
|
11 |
|
12 |
|
13 |
|
15 |
|
16 |
|