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

Neo4j: Faster way to get the number of nodes of all the subgraphs

I have a graph which consist of millions of disconnected subgraph. Now I am trying to find the number of nodes for all of these subgraphs. For example, lets say I have this graph which contains A-B-C, D-E, F-G-H. So the return will be 3, 2, 3. Now I…
sjishan
  • 3,392
  • 9
  • 29
  • 53
0
votes
0 answers

Calling apoc.export.graphml.query generates IllegalStateException in Neo4J

I'm using the neo4J APOC library, and using the export/import functionality. apoc.export.graphml.all works great, and is able to extract everything it once, however, when the query version is called, it is not able to do so. The same is the case…
Rajat Jain
  • 452
  • 1
  • 6
  • 16
0
votes
1 answer

Confused about using ORDER BY correctly

I am experimenting with dates in neo4j. Now I'd like to sort my results by the ISODateString. I created a cypher query like this: MATCH(e:Expedition {id : "BJGYmzwZb"})-[pje]-(u:User) WHERE (e)-[:POSSIBLY_JOINS_EXPEDITION]-(u) OR…
janwo
  • 754
  • 2
  • 8
  • 17
0
votes
1 answer

When and How to run pagerank algorithm in neo4j?

I build a Data model with Nodes with labes: User, Post, Comment, Page, Group Relationships: FOLLOW(User->User/Page), WRITE(User->Post/Comment), LIKE(User->Post/Comment), AT(between Post and Comment), HAS(between Post and Group),…
kien bui
  • 1,760
  • 2
  • 17
  • 33
0
votes
1 answer

Bond two differents graphs algorithms using APOC in neo4J

I am using Neo4J to store a network topology and execute some graphs algorithms like Dijkstra and allSimplePaths (using apoc procedures). I need to know if is possible use the output of allSimplePaths as input to the Dijkstra algorithm. In other…
B. André
  • 3
  • 1
0
votes
0 answers

apoc.spatial.geocode() throws RuntimeException

I'm facing this error: Failed to invoke procedure "apoc.spatial.geocode": Caused by: java.lang.RuntimeException: Can't read url http://nominatim.openstreetmap.org/search.php?format=json&q=Duomo+Milano as json: Connection refused: connect when I…
gios
  • 1
  • 1
0
votes
1 answer

How to call apoc.map.groupBy() correctly?

When I call this: MATCH (node:Wallet) WITH collect(node) AS nodes CALL apoc.algo.pageRankWithConfig(nodes,{types:'SendTo'}) YIELD node, score WITH nodes, collect({id:toString(id(node)),score:score}) as ranks call apoc.map.groupBy(ranks,'id') as…
Aqqqq
  • 816
  • 2
  • 10
  • 27
0
votes
1 answer

Can't create relationship when add trigger in neo4j

I created a trigger with apoc.trigger.add: CALL apoc.trigger.add('increase_followings_and_followers', 'UNWIND {createdRelationships} AS rel WITH rel, STARTNODE(rel) as follower, ENDNODE(rel) AS followed WITH rel, follower, followed WHERE…
kien bui
  • 1,760
  • 2
  • 17
  • 33
0
votes
1 answer

How to use apoc.refactor.mergeNodes([])

How to merge nodes in a query with apoc.refactor.mergeNodes([]) and then do something about the merged node? When I use this: WITH w2, minW, minW {.*} as snapshot call apoc.refactor.mergeNodes([minW,w2]) YIELD reW SET reW.first_seen =... This error…
Aqqqq
  • 816
  • 2
  • 10
  • 27
0
votes
1 answer

How to parse the date in the form of "yyyy-mm-ddTHH:mm:ss" with apoc in neo4j?

I have the same problem as described here: http://www.markhneedham.com/blog/2017/03/06/neo4j-apoc-date-parse-java-lang-illegalargumentexception-illegal-pattern-character-t-java-text-parseexception-unparseable-date-2012-11-12t084615z/ Is there anyway…
Aqqqq
  • 816
  • 2
  • 10
  • 27
0
votes
1 answer

Why does this apoc code not work in browser?

I ran CALL apoc.date.parseDefault('1969-07-21 02:56:15', 's') YIELD value in the browser of neo4j. But it does not work. The error is: There is no procedure with the name apoc.date.parseDefault registered for this database instance. Please ensure…
Aqqqq
  • 816
  • 2
  • 10
  • 27
0
votes
1 answer

Using Neo4j Java API property Container

I am trying to update a apoc plugin for Gephi, so that I can send weights from Neo4j to Gephi. This is the original version of the plugin. What was my thinking that I could easily rearrange private Map data(PropertyContainer pc,…
Tomaž Bratanič
  • 6,319
  • 2
  • 18
  • 31
0
votes
1 answer

XOR, AND Tree in Neo4j Cypher

I have a problem trying to "decypher" a logical tree with Neo4js Cypher. I have a logical tree of Operation to Leaves. I want to collect valid sets of Leaves. I am currently trying to collect valid Sets of Leaves on a Valid Configuration Node. So I…
samst
  • 536
  • 7
  • 19
0
votes
1 answer

Missing some APOC procedures after installing latest APOC onto Neo4j 3.1.1

I installed the Neo4j APOC Stored Procedures but I only seem have access to some of the procedures. For example when I run "CALL apoc.convert.toJson([1,2,3])" I receive an error message: There is no procedure with the name apoc.convert.toJson…
n4nite
  • 459
  • 4
  • 19
0
votes
2 answers

Neo4J Cypher query creates more links than expected

In the following query (which I modified from one I found on the net). I am using APOC to create 14 nodes, and what I though would be 12 edges (connecting each of the nodes in two rows). I.e. if you take 14 nodes, and put then in two columns of 7…
Dr.YSG
  • 7,171
  • 22
  • 81
  • 139
1 2 3
45
46