Wolfgang-Schuetzelhofer / jcypher

Java access to Neo4J graph databases at multiple levels of abstraction
Apache License 2.0
86 stars 15 forks source link

Match Node with ID #35

Closed utkarsh3107 closed 6 years ago

utkarsh3107 commented 6 years ago

I'm sorry if this seems to vague but I would like to know how I can make the below cypher:

MATCH (N)
 WHERE id(N) = <some_node_id>
 return N;
Wolfgang-Schuetzelhofer commented 6 years ago

Sorry for the late answer, if you have a node id you should better use START like so:

JcNode n = new JcNode("n"); clauses = new IClause[]{ START.node(n).byId(1234), RETURN.value(n) };

this translates to the following CYPHER expression: START n = node(1234) RETURN n

best regards, Wolfgang