Neo4j CQL Operators
Neo4j CQL Operators can be categorized in following types:
- Mathematical Operators: i.e. +, -, *, /, %, ^
- Comparison Operators: i.e. +, <>, <, >, <=, >=
- Boolean Operators: i.e. AND, OR, XOR, NOT
- String Operators: i.e. +
- List Operators: i.e. +, IN, [X], [X?..Y]
- Regular Expression: i.e. =-
- String matching: i.e. STARTS WITH, ENDS WITH, CONSTRAINTS
Let's see the two most used Neo4j CQL Operators:
Boolean Operators
Following is a list of Boolean operators which are used in Neo4j CQL WHERE clause to support multiple conditions:
Index |
Boolean operators |
Description |
1. |
AND |
It is a neo4j CQL keyword to support AND operation. It is like SQL AND operator. |
2. |
OR |
It is a Neo4j CQL keyword to support OR operation. It is like SQL AND operator. |
3. |
NOT |
It is a Neo4j CQL keyword to support NOT operation. It is like SQL AND operator. |
4. |
XOR |
It is a Neo4j CQL keyword to support XOR operation. It is like SQL AND operator. |
Comparison Operators
A list of Neo4j CQL Comparison Operators used with WHERE clause:
Index |
Boolean operators |
Description |
1. |
= |
It is a Neo4j CQL "equal to" operator. |
2. |
< > |
It is a Neo4j CQL "not equal to" operator. |
3. |
< |
It is a Neo4j CQL "less than" operator. |
4. |
> |
It is a Neo4j CQL "greater than" operator. |
5. |
<= |
It is a Neo4j CQL "less than or equal to" operator. |
6. |
> = |
It is a Neo4j CQL"greater than or equal to" operator. |
|