Found the answer: $ echo "call apoc.cypher.runTimeboxed('match (n:Entity)-[*4]-() where n.name=\"hello\" return n.name;',null, 10000);" | ~fred/neo4j/bin/cypher-shell The transaction has been terminated. Retry your operation in a new transaction, and you should see a successful result. Explicitly terminated by the user.
Bye! On Wednesday, 22 March 2017 12:43:48 UTC, unreal...@googlemail.com wrote: > > > Thanks for the prompt response. > > Further question: > > This works from the Web GUI: > > call apoc.cypher.runTimeboxed('match (n:Entity)-[*4]-() where n.name="hello" > return n.name;',null, 10000) > > Why doesn't this work: > echo "call apoc.cypher.runTimeboxed('match (n:Entity)-[*4]-() where > n.name="hello" > return n.name;',null, 10000)" | ~fred/neo4j/bin/cypher-shell > > Bye! > > > On Wednesday, 22 March 2017 10:35:27 UTC, Benoît Simard wrote: >> >> Hi, >> >> There is a procedure to do that in APOC, called >> `apoc.cypher.runTimeboxed` >> Check the documentation >> https://neo4j-contrib.github.io/neo4j-apoc-procedures/#_cypher_execution >> >> Cheers >> >> 2017-03-22 11:09 GMT+01:00 unrealadmin23 via Neo4j < >> ne...@googlegroups.com>: >> > >> > It would be good to be able to specify a maximum run time of a query - >> I >> > know that you can set this as a global parameter but on a per query >> basis >> > would be very useful in some circumstances. >> > >> > i.e. >> > >> > match ()......... return a timeout=10; >> > >> > Wayne >> > >> > -- >> > You received this message because you are subscribed to the Google >> Groups >> > "Neo4j" group. >> > To unsubscribe from this group and stop receiving emails from it, send >> an >> > email to neo4j+un...@googlegroups.com. >> > For more options, visit https://groups.google.com/d/optout. >> > -- You received this message because you are subscribed to the Google Groups "Neo4j" group. To unsubscribe from this group and stop receiving emails from it, send an email to neo4j+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.