Last active
December 29, 2015 23:04
-
-
Save Btibert3/cfec2c103885efeb6ba9 to your computer and use it in GitHub Desktop.
Quick Helper Function to use Neo4j Shell for LOAD CSV. Sets the shell tool and expects a file path. Very alpha but it works.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## a function to import cypher statements into the shell | |
build_import = function(NEO_SHELL="~/neo4j-community-2.3.1/bin/neo4j-shell", | |
cypher_file) { | |
cmd = sprintf("%s -file %s", NEO_SHELL, cypher_file) | |
system(cmd) | |
} | |
## example | |
## import the database from scratch | |
## build_import(cypher_file="import-db.cql") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment