Supported mandatory GQL features

Unlike optional GQL features, mandatory GQL features are not assigned a GQL feature ID code. The below table is instead listed in order of their appearance in the ISO/IEC 39075:2024(en) GQL Standard.

GQL Standard subclause Description Documentation Comment

4.11

Graph pattern matching

4.13

GQL object types

Includes: NODE (ANY NODE, VERTEX, ANY VERTEX) and RELATIONSHIP (ANY RELATIONSHIP, EDGE, ANY EDGE).

4.16

Predefined value types

Includes: BOOLEAN (BOOL), FLOAT, INTEGER (SIGNED INTEGER, INT), and STRING (VARCHAR).

Cypher supports the boolean type predicate for TRUE, FALSE, and NULL but does not support the GQL keyword UNKNOWN.

13.2

<insert statement>

13.3

<set statement>

SET

GQL’s SET has no order dependencies because all right-hand side operations are completed before any assignments occur. In Cypher’s SET, the order of rows can affect the outcome because changes made during execution may depend on the sequence of assignments. The only way to guarantee row order in Neo4j is to use ORDER BY.

13.4

<remove statement>

13.5

<delete statement>

14.4

<match statement>

14.9

<order by and page statement>

Cypher only supports SKIP, which is a GQL-supported synonym to OFFSET.

14.10

<primitive result statement>

14.11

<return statement>

15.1

<call procedure statement> and <procedure call>

GQL defines an OPTIONAL CALL statement, enabling optional procedure and subquery calling. This is not available in Cypher.

15.2

<inline procedure call>

GQL either imports variables implicitly, or explicitly using a variable scope clause. In Cypher, CALL subqueries require an explicit importing WITH clause.

15.3

<named procedure call>

16.2

<limit clause>

16.4

<graph pattern>

16.5

<insert graph pattern>

16.6

<order by clause>

16.7

<path pattern expression>

16.8

<label expression>

16.9

<path variable reference>

16.11

<graph pattern quantifier>

16.17

<sort specification list>

16.19

<offset clause>

Cypher only supports SKIP , which is a GQL-supported synonym to OFFSET.

19.3

<comparison predicate>

19.4

<exists predicate>

19.5

<null predicate>

19.6

<value type predicate>

19.7

<normalized predicate>

20.2

<value expression primary>

20.3

<value specification>

GQL defines the SESSION_USER value expression, which enables accessing a user’s username within a query. In Cypher, current user details can be seen using the SHOW CURRENT USER command.

20.7

<case expression>

20.9

<aggregate function>

Cypher and GQL handle NULL values differently for the sum() function when queries return 0 rows. For example, RETURN sum(<expr>) on an empty table returns NULL in GQL, but in Cypher it returns 0.

20.11

<property reference>

20.21

<numeric value expression>

20.22

<numeric value function>

20.23

<string value expression>

20.24

<character string function>

In GQL, TRIM() removes only space characters. In Cypher, trim() removes any whitespace character.

21.1

Names and variables

Cypher supports GQL’s lexical elements, with the following caveats:

  • GQL allows for extended parameter identifiers. For example: RETURN $0hello is allowed in GQL but not Cypher.

  • GQL allows identifiers that are not variables to be delimited with both backticks and quotes. Cypher only allows backticks. For example: MATCH (n) RETURN n."a prop" is allowed in GQL but not Cypher.

22.15

Grouping operations