Faster way to insert data in neo4j? -
Faster way to insert data in neo4j? -
i trying insert unique nodes , relationship in neo4j.
what using :-
neo4j community edition running on amazon ec2.[amazon linux m3.large] neo4j java rest binding [ https://github.com/neo4j-contrib/java-rest-binding ]data size , type :
tsv file [multiple]. each contains more 8 1000000 lines [each line represent node or relationship].there more 10 files nodes.[= 2 1000000 nodes] , 2 1000000 relations.
i using uniquenodefactory inserting nodes. , inserting sequentially, couldn't find way insert batches preserving unique nodes.
the problem is taking huge time insert data. illustration took day inserting 0.3 1000000 unique nodes. there way fasten insertion?
don't that.
java-rest-binding never made that.
use either
using periodic commit 1000 load csv headers "http://some.url" line create (u:user {name:line.name})
you can utilize merge (with constraints), create relationships etc.
see blog post example: http://jexp.de/blog/2014/06/using-load-csv-to-import-git-history-into-neo4j/ or neo4j manual: http://docs.neo4j.org/chunked/milestone/cypherdoc-importing-csv-files-with-cypher.html
neo4j
Comments
Post a Comment