EctoNeo4j v0.6.3 Ecto.Adapters.Neo4j.Cql.Relationship View Source

Cypher query builder for Node

Link to this section Summary

Functions

Get cql to retrieve relationships between the two speccified nodes.

Link to this section Functions

Link to this function

get_related(start_node_label, end_node_label, where) View Source
get_related(String.t(), String.t(), String.t()) :: String.t()

Get cql to retrieve relationships between the two speccified nodes.

Example

iex> where = "n0.uuid = {uuid}"
iex> Ecto.Adapters.Neo4j.Cql.Relationhip.get_related("User", "Post", where)
"MATCH
  (n0:User)-[rel]->(n:Post)
WHERE
  n0.uuid = {uuid}
RETURN
  COLLECT(rel) AS relationships, n

"