Reputation: 793
I'm using Neo4j v 4.0.3 on Azure. Python code is used to load the database. Standard cypher create queries work as expected:
Create (n:xxx{name:'xxx'})
However, this does not work:
LOAD CSV With HEADERS FROM 'https://neo4jclusterdiag.blob.core.windows.net/neo4j-import/jTags.csv?{SAS}' AS line FIELDTERMINATOR '|' MERGE (p:AncestryTag{TagId: toInteger(line.TagId),color:toString(line.Color),Label:toString(line.Label)})
The CSV is simple:
TagId|Color|Label
1000|#6ba410|Brydie Scotland
1001|#FFE300|Scroggie
1002|#e3720f|Brodie Scotland
1003|#f06158|Robertson Scotland
1004|#cb478a|Goolsby
1005|#655586|Watt Aberdeenshire
1006|#0079a3|Milne Scotland
1007|#489b9b|Hay Aberdeenshire
1008|#FFB800|Anderson
1009|#a94500|Thomas
1010|#871a13|Bain, McBain
I have a separate local install on Neo4j v 4.0.3 and the LOAD CSV works fine there. So it's something amiss with the Azure database.
I've made the following changes in the config file:
#dbms.directories.import=/var/lib/neo4j/import
dbms.security.allow_csv_import_from_file_urls=true
I try running the LOAD CSV from python code or within the Neo4j browser. Same error with both:
neobolt.exceptions.ClientError: Couldn't load the external resource at: https://neo4jclusterdiag.blob.core.windows.net/neo4j-import/jTags.csv?{SAS}
In the browser I also see:
Neo.ClientError.Statement.ExternalResourceFailed
I can place this in my browser address window and retrieve the file:
https://neo4jclusterdiag.blob.core.windows.net/neo4j-import/jTags.csv?{SAS}
Thus, there is something specifically wrong with my Azure database not recornizing the file I'm trying to import using load csv.
Upvotes: 1
Views: 120