Questions tagged [neo4j-apoc]

APOC is short for "Awesome Procedures on Cypher." Introduced in Neo4j release 3.0, APOCs are callable procedures which extend the Cypher query language.Questions with the neo4j-apoc tag should be for "small, generic helper functions for common tasks" that are not available in the Cypher query language.

APOC procedures are "User Defined Procedures." They are similar to stored procedures in some relational databases. APOCs can be written in any language that runs on the JVM. Questions tagged with neo4j-apoc should have an accompanying tag for the specific language being used.

Built in procedures are included in Neo4j releases. Before posting a question on StackOverflow, please consult the Neo4j documentation and ask if your task is possible in the public chat channels.

685 questions
0
votes
0 answers

APOC procedure for XML by JavaAPI

I'm using Neo4J API and I need to import an XML file. On Neo4j I successfully use the following procedure: call apoc.xml.import("myfile.xml") yield node return node; but I do not know how to reproduce this function by Java API. As far as I know I…
Wall
  • 293
  • 3
  • 13
0
votes
0 answers

Neo4j explicit/manual index queries, parameters in predicate and possible Cypher(SQL) injections

I'm going to use Neo4j explicit/manual index queries, something like that: MATCH (d:Decision)-[:HAS_VALUE_ON]->(ch:Characteristic) WHERE ch.id = 2 CALL apoc.index.in(ch,'HAS_VALUE_ON','property.1.4:5 AND property.1.3:"practical"') YIELD node AS…
alexanoid
  • 24,051
  • 54
  • 210
  • 410
0
votes
1 answer

Neo4j APOC remove all triggers

I'd like to implement Cypher query and using APOC functions remove all of the existing triggers: I'm trying the following query: CALL apoc.trigger.list() yield name CALL apoc.trigger.remove(name) yield name, installed but it fails with the…
alexanoid
  • 24,051
  • 54
  • 210
  • 410
0
votes
1 answer

Neo4j: Filter paths to include paths with unique intermediate nodes only

I am using the following neo4j cypher query on my graph: MATCH (start:N1{id:'xyz'}) CALL apoc.path.expandConfig(start, {sequence:'N1, a>, N2, b>, N3, c>, N4', maxLevel:3}) YIELD path RETURN path ORDER BY length(path) DESC This returns all paths…
0
votes
2 answers

Neo4j APOC assignedRelationshipProperties, removedRelationshipProperties triggers and apoc.index.in

I use Neo4j 3.3.5 Community Edition with APOC apoc-3.3.0.2-all.jar I have triggers that allow me to add/remove all properties from a particular relationships to/from manual index: CALL…
alexanoid
  • 24,051
  • 54
  • 210
  • 410
0
votes
1 answer

Neo4j APOC verify trigger already exists

I use Neo4j APOC in order to install the following trigger: CALL apoc.trigger.add('HAS_VALUE_ON_ADD_TO_INDEX', 'UNWIND {createdRelationships} AS r MATCH (d:Decision)-[r:HAS_VALUE_ON]->(ch:Characteristic) CALL apoc.index.addRelationship(r, keys(r))…
alexanoid
  • 24,051
  • 54
  • 210
  • 410
0
votes
1 answer

Neo4j APOC subsequent chain of functions in the Cypher query

I need to organize into the subsequent chain (1..N calls) of apoc.index.in function, something like this: MATCH (d:Decision)-[:HAS_VALUE_ON]->(ch:Characteristic) WHERE ch.id = 10 CALL apoc.index.in(ch,'HAS_VALUE_ON','property.2.5:7 AND value:45')…
alexanoid
  • 24,051
  • 54
  • 210
  • 410
0
votes
0 answers

Neo4j APOC remove trigger

I need to delete APOC trigger. The following call works fine in case the trigger already exists: CALL apoc.trigger.remove('RELATIONSHIP_INDEX_ADD_HAS_VALUE_ON'); but fails with the following…
alexanoid
  • 24,051
  • 54
  • 210
  • 410
0
votes
1 answer

Use of apoc.periodic.commit or other approaches for batching large serial query

I've been advised to use apoc.periodic.commit to batch up a large query I'm running in neo4j. My code below doesn't seem to be batching up and committing though after each step though. Server runs out of memory, which I think it shouldn't if commits…
DanBennett
  • 448
  • 2
  • 5
  • 17
0
votes
1 answer

Neo4j some procedures are missing

I am using APOC 3.3.0.1. dbms.security.procedures.unrestricted=algo.*, apoc* Not sure why there are some procedures missing in my…
mlo0424
  • 359
  • 2
  • 4
  • 16
0
votes
2 answers

Neo4j Cypher chain output from match query to APOC

I wanted to make use of the Neo4j Cypher apoc.index.search procedure. I am currently using the Neo4j CE 3.1.0. I have successfully set up and tested the procedure as a stand-alone query such as: call apoc.index.search("Contact2",…
HT1
  • 61
  • 2
  • 11
0
votes
1 answer

Run a query to form relationship in neo4j

I am running a query in cypher shell to form relationship between 10 million nodes.The query is CALL apoc.periodic.iterate( "MATCH (a:HeaderRecord), (b:FormationRecord) WHERE a.WellID = b.WellID CREATE (a)-[rel:HAS_FORMATION]->(b) RETURN…
Anshul Gupta
  • 71
  • 2
  • 6
0
votes
1 answer

Where the method findAllPaths of PathFinder is Overrode in the apoc procedures repo?

I am trying to add a maxDepth for Dijkstra's search. I've looked in the apoc procedures repo source code and found out that they pass the PathFinder alongside the startNode and enNode in WeightedPathResult.streamWeightedPathResult which calls the…
0
votes
1 answer

I had upgraded my neo4j dekstop from 3.3.3 to 3.3.5 , but getting compatibility issue with APOC?

I also try to add plugin manually as suggested in APOC procedure not found but not nothing seems worked, please help me out. Find screenshot here
jatin patware
  • 141
  • 1
  • 12
0
votes
0 answers

Neo4j - Pass Variable to apoc.cypher.runFile CALL

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…
Mark Davydov
  • 337
  • 4
  • 18