0
votes

How to rename a node in a graph in neo4j without tempering the relationships of that node. Also how to delete a relationship between two nodes. please assist me with the cypher syntax.

1
What is for you rename a node ? What have tried so for ?logisima

1 Answers

0
votes

You can find many tips in the official documentation

How to delete relationship

MATCH (n { name: 'Andres' })-[r:KNOWS]->()
DELETE r

How to add a new label

MATCH (n { name: 'Stefan' })
SET n:German
RETURN n.name, labels(n) AS labels

How to remove a label

MATCH (n { name: 'Peter' })
REMOVE n:German
RETURN n.name, labels(n)