Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.
12-02-2021 04:57 PM
Hi all,
running the neo4j
Neo4j Browser version: [4.3.3]
Neo4j Server version: 4.2.11
ad trying LOAD CSV - Neo4j Cypher Manual
and putting the csv file to my gitlab repository
LOAD CSV WITH HEADERS FROM 'https://git.......net/product/neo4j/-/blob/master/resources/data.csv' AS line CREATE (:Artist {name: line.Name, year: toInteger(line.Year)})
i am getting
At https://git.........net/product/neo4j/-/blob/master/resources/data.csv @ position 47396 - there's a field starting with a quote and whereas it ends that quote there seems to be characters in that field after that ending quote. That isn't supported. This is what I read: '#8fbc8f":'
🙂 But i dont have anywhere quotes, i am using the same structure from the example
Id,Name,Year
1,ABBA,1992
2,Roxette,1986
3,Europe,1979
4,The Cardigans,1992
Any idea what is wrong?
Thank you
12-03-2021 06:23 AM
Hi .
can please you try :
CREATE CONSTRAINT UniqueName ON (k:Artist) ASSERT k.name is unique ;
LOAD CSV WITH HEADERS FROM 'https://git .......net/product/neo4j/-/blob/master/resources/data.csv' AS line
MERGE (a :Artist {name: toString(line.Name) })
on create set a.year=toInteger(line.Year)
12-03-2021 10:42 AM
Cannot merge the following node because of null property value for 'name': (a:Artist {name: null}) (Failure when processing file '/product/neo4j/-/blob/master/resources/data.csv' on line 2.)
i have tryed to moved the file to git hub reporository
and from there data was loaded, funny is that structure is weird, cause it create 1200 nodes in format
{
"identity": 258,
"labels": [
"Artist"
],
"properties": {
}
}
but at least its doing something. So my previous error is probably caused by some interna access isssue to the company gitlab and the data which is trying to parse are some exception message.
Marek
All the sessions of the conference are now available online