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
2
votes
2 answers

How to build a Cypher / APOC query in Neo4J 3.x which searches on two different relationship types?

Currently I use the following Cypher / APOC query to search the relationship type TO by a certain property (user id): CALL apoc.index.relationships('TO','user:16c01100-aa92-11e3-a3f6-35e25c9775ff') YIELD rel, start, end WITH DISTINCT rel, start,…
Aerodynamika
  • 7,883
  • 16
  • 78
  • 137
2
votes
1 answer

APOC plugin for Neo4j

I tried to install APOC plugin for my Ubuntu VBox. Neo4j version: 3.3.1 Downloaded the JAR: apoc-3.3.0.1-all.jar and placed it into /var/lib/neo4j/plugins Restarted the server but calling RETURN apoc.verison() prompts me: Unknown function…
TaylorR
  • 3,746
  • 5
  • 25
  • 42
2
votes
2 answers

Adding millions of nodes to neo4j spatial layer using cypher and apoc

I have a data set of 3.8million nodes and I'm trying to load all of these into Neo4j spatial. The nodes are going into a simple point layer, so have the required latitude and longitude fields. I've tried: MATCH (d:pointnode) WITH collect(d) as pn…
SAB
  • 175
  • 17
2
votes
1 answer

Is there a way to call apoc.create.node such that it will not fail if one or more of the nodes cannot be created due to a duplicate key?

I am running apoc.create.node against a .CSV file. I need the nodes that can be created to be created even if one or more nodes fails due to a duplicate key. I run this: CALL…
nicomp
  • 4,344
  • 4
  • 27
  • 60
2
votes
1 answer

Can I call 2 apoc procedures and combine the result sets in cypher?

I would like to call 2 different procedures and combine the output for further matches in one cypher query. Is it possible? So, to make it more clear: I have created a manual index which I use in my queries with call…
Ira Re
  • 730
  • 3
  • 9
  • 25
2
votes
1 answer

neo4j APOC does not work locally on Win10

edit: Using Neo4j Community Edition 3.2.1. I successfully installed APOC on my remote machine (debian) and it's working just fine. However locally (Win10) I can't seem to get it to work. What I did: pasted the jar into the plugins folder tried to…
tscherg
  • 1,032
  • 8
  • 22
2
votes
1 answer

Apoc Dijkstra traversing in both directions while computing shortest path

I've been trying to use neo4j and its apoc process library to get shortest path between 2 nodes. For example I create 2 nodes as below CREATE (:Point {title:'A'}) CREATE (:Point {title:'B'}) Then I establish their relationship as such MATCH…
MrRo
  • 53
  • 5
2
votes
3 answers

There is no procedure with the name `apoc.periodic.iterate`

I'm running Neo4j (v 3.1.3) within a Docker (v17.05.0-ce-rc1) container on OSX (v10.11.6) and I've "installed" the APOC jar file, see: $ docker exec -it sandbox-db ls /plugins apoc-3.1.3.6-all.jar I also see the container is properly configured to…
ekkis
  • 9,804
  • 13
  • 55
  • 105
2
votes
1 answer

Neo4j: optimum path search

Having a graph of people who like rated movies, I would like to extract for each pair of people their highest rated movie. I'm using the following query which requires sorting movies on their rate for each pair of people. MATCH (p1:People)…
Pierre
  • 885
  • 2
  • 10
  • 25
2
votes
1 answer

Cypher-How to set property for the nodes along the shortestpath

I'm new to neo4j and cypher, with about a week's experience... I'm working on a small project to manipulate with a graph of the 10s of thousands of TWS batch jobs running on the mainframe of my company. A key mission is to found out what we called…
AlexDxl
  • 23
  • 5
2
votes
1 answer

Failed to restart after installed APOC Plugin in Neo4j

I would like to install the APOC plugin for Neo4j. However once generated jar file and restart, neo4j not able to restart again Follow Guide https://github.com/neo4j-contrib/neo4j-apoc-procedures/tree/3.1 Error msg: ERROR Failed to start Neo4j:…
hellowong
  • 119
  • 12
1
vote
0 answers

How can I add string variables into SET request using official Neo4j Python Drive?

Since py2neo isn't quite compatible with the latest Neo4j, I chose to use the official Neo4j Python Driver. My purpose I've been trying to add a string variable into the Driver.execute_query() method's cypher SET request. My purpose is using…
1
vote
1 answer

How to fix create node index error in neo4j?

neo4j version: 5.7.0 apoc: 5.7.2 GDSL: 2.3.6 I have a nestjs app using a neo4j DB, in which I want to create a index like this: CALL db.index.fulltext.createNodeIndex( "FTS_Person_Company_fullName", ["Person", "Company"], ["fullName"], …
Mike Peter
  • 11
  • 1
1
vote
2 answers

How to keep result of first "MATCH" when a later called procedure returns no records

This is my Query: MATCH (a:Person {name: "Stefan"}) MATCH (p:Person {name: "not_a_real_name"}) CALL apoc.path.subgraphNodes(p, { relationshipFilter: "KNOWS" }) YIELD node AS b RETURN a a and b will always return (no records) since…
1
vote
2 answers

Neo4j ERROR (Neo.ClientError.Procedure.ProcedureCallFailed)

I am new to Neo4j. I tried to create "Account" nodes and "Trade_History" relations at the same time using apoc.import.csv. CALL apoc.import.csv( [{fileName: "file:///Account.csv", labels: ['Account']}], [{fileName:…
newbie
  • 19
  • 4