cancel
Showing results for 
Search instead for 
Did you mean: 

Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.

Backticks and neo4j javascript driver

fred
Node Link

Hi,

I am wondering if there is a more elegant way to write queries where you have to escape characters from the neo4j driver?

This is my current solution:

session.run(
        'CALL apoc.load.json({sourcejsonfile})
        YIELD value
        WITH value, value.`$` AS document \
        RETURN document
).then()...

Note that because of the need to escape the character with a ` (backtick) I have to then use backslashes to break the lines inside the query.

Thank you,
Fred

1 REPLY 1

fred
Node Link

answering my own question: I found this Lib https://www.npmjs.com/package/cypher-tagged-templates