Step - gql

gql ยท category: Start

Runs a GQL query (experimental: MATCH, OPTIONAL MATCH, WHERE, LET, FILTER, WITH, RETURN with aggregates, ORDER BY, OFFSET, LIMIT, quantified edges and path patterns, path variables, and the writes INSERT / CREATE, SET, REMOVE, [DETACH] DELETE and MERGE; $name reads a value of the optional parameter map) at the start of a traversal; each row is a map from column name to value, and Gremlin steps may follow.

Forms

gql(arg1: string)
gql(arg1: string, arg2: any)

Example

g.gql("MATCH (p:person) WHERE p.age > $min RETURN p.name AS name ORDER BY name", #{min: 30}).to_list()   // [#{"name": "josh"}, #{"name": "peter"}]

See also