I made some wrong moves in Neo4j, and now we have a graph with duplicate nodes. Among the duplicate pairs, the full property set belongs to the first of the pair, and the relationships all belong to the second in the pair. The index is the node_auto_index.
Nodes:
Id Name Age From Profession
1 Bob 23 Canada Doctor
2 Amy 45 Switzerland Lawyer
3 Sam 09 US
4 Bob
5 Amy
6 Sam
Relationships:
Id Start End Type
1 4 6 Family
2 5 6 Family
3 4 5 Divorced
I am trying to avoid redoing the whole batch import. Is there a way to merge the nodes in cypher based on the "name" string property, while keeping all of the properties and the relationships?
Thank you!