I am trying to run queries from the neo4j browser to reproduce results from my neo4j-javascript-driver client.
What is the syntax for defining query parameters in the neo4j b
I recently attended a neo4j training session in NYC where the trainer (David Fauth) did this, unfortunately, I did not take notes on it, since I figured that I could read-up on this online...but no success.
To set a parameter in Cypher Shell use :param name => 'Joe' . For more information refer to Operations Manual → Cypher Shell - Query Parameters. For Neo4j Browser use the same syntax as Cypher Shell, :param name => 'Joe' .
Neo4j Browser is the easiest way to access a Neo4j database. To establish a connection, you enter the DBMS URL, the name of the database you want to connect, and the user credentials. You can also use the :server command to manage the connection to Neo4j.
In neo4j-browser you need type for example:
:params {nodes: [{name: "John", age: 18}, {name: "Phill", age: 23}]}
Then you can use params as usual:
UNWIND {nodes} as node MERGE (A:User {name: node.name, age: node.age}) RETURN A
For clear params in neo4j-browser type :params {}
.
For additional help type :help params
.
In Neo4j-3.3.4, the cypher likes this:
:param nodes: [{name: 'John', age: 18}, {name: 'Phill', age: 23}]
Neo4j Browser result: here
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With