0

I have a .cypher file that I want to run using jdbcOperations like this:

jdbcOperations.update("CALL apoc.cypher.runFile(\""+{CYPHER FILE HERE}+"\")");

But,

In that cypher file I have another CALL

CALL apoc.load.json({PATH TO JSON FILE HERE}) YIELD value AS item

I want that JSON File Path to be dynamic, to pass the path to it as a variable , but I have not succeed with any of my tries.

Help ?

Mark Davydov
  • 337
  • 4
  • 18
  • I think it's just not possible ... a file is a static ressources, and it should be sufficient to execute its self. On queries, you can give parameters. But stupid question, why are you doing this ? Why are you not executeing the query directly ? – logisima Apr 10 '18 at 14:37
  • @logisima That question wasn't stupid at all :) I was trying to add functionality for an existing module without a need to refactor a pieces of code, I have tried a lot of different approaches, without any success though. – Mark Davydov Apr 11 '18 at 06:12
  • @logisima Any best practices on executing a big Cypher via jdbcOperations? For an example if I will store it as a String. – Mark Davydov Apr 11 '18 at 06:13
  • There is nothing particular with a jdbcOperations ... so if you follow the good cypher practice, it will be enought. Can you give an example of a `Big Cypher` ? – logisima Apr 11 '18 at 20:12

0 Answers0