Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.
06-25-2019 12:55 AM
Hi, I am new to Neo4j and I couldn't find the answer directly by looking for it in this forum.
I want to create relationships from a csv on already existing nodes.
These are the CSV's I have with the following data:
object.csv
unid,name
object-link.csv
unid,parentid,childid
The parentid/childid's from the object-link.csv are matching the unids from object.csv. How can I connect the parents to the childs from the object-link.csv?
Thanks!
06-25-2019 07:08 AM
Assuming you created a Person node with unid, name as properties from object.csv
From object-link.csv
MATCH (p:Person) WHERE p.unid = line.parentid
MATCH (p1:Person) WHERE p1.unid = line.childid
WITH p, p1, line
MERGE (p)-[:PARENT_OF]->(p1)
All the sessions of the conference are now available online