Hello all,
i have started to get more than newbie by starting to import data to my neo4j desktop.
I had success when I imported few data (156 nodes). Then when I wanted to import csv for relationship I face constantly the same problem, and I couldnt find any answer resolving it, I had to connect 156 nodes to another 15 nodes. And the same query I was using constantly showed me
no changes no records` error message. // So I asked myself does the free version of Neo4j limitating too much the total nodes and relationships allowed? IF anyone has any answer about it, it will be nice.
if there is a limit? certainly not < 200+/-nodes
this sounds more like an issue with the cypher.
can you post the cypher which indicates 'no changes'.
Thanks for the reply. I am trying to add relationship between existing nodes. Here is the code:
LOAD CSV WITH HEADERS FROM "file:///tch_city.csv" AS csvLine
MATCH (Tch:teach {tch_id: toInteger(csvLine.tch_id)}),(Cty:city {cty_id: toInteger(csvLine.cty_id)})
MERGE (Tch-[live:LIVES_IN]->(Cty);
the cypher effectively says
a. find me a node with :teach label and property tch_id = the Integer representation of csvLine.tch_id
b. find me a node with label :city and property cty_id = the Integer representation of csvLine.cty_id
c. the create or update a relationship. However the MERGE is syntactically incorrect, and not sure if it was a typo here or the actual cypher. But the typo appears to be (Tch-[live:....
when I think it should be (Tch)-[live:....
so its either the typo in c. or if not trying running the load csv ... and just have it do the match as from a. or try running the load csv ... and just have it do the match as from b.
I got the solution, but I was dumb, here is what happened:
(I am sorry for the weird thing I did)
My original non-working code was like this:
//
MATCH (Tch:teach {TTTeach: toInteger(csvLine.tch_id)}),(Cty:city {CCCty: toInteger(csvLine.cty_id)})
//
When asking the question I erroneously wrote the right code
here:
//
MATCH (Tch:teach {tch_id: toInteger(csvLine.tch_id)}),(Cty:city {cty_id: toInteger(csvLine.cty_id)})
//
I`m so sorry for my dumbness. And thank you.
Tell me if I understood my error: my mistake was to say to Cypher this: connect CCCty on the database to cty_id in the csv file. And it fact, cypher is only able to connect if only
the both fields name are exactly the same.
last note: maybe I am making a mistake here again, but I haven t read in any Neo4j tutorial explaining the relationship batch uploading, by including this subtile important detail
.
If this is the case I will be glad having a support to the community. If not: sorry another dumb message