I'm trying to make a game using the neo4j graph database as an experiment. Some nodes are Users and some nodes are Rooms. Rooms have a CONTAINS relationship to Users so the database has a lot of this: (someroom)-[CONTAINS]->(someuser)

When a User leaves a Room and enters another in the game, the CONTAINS relationship needs to reflect that by detaching from the Room and reattaching to a different Room. Is there a way to do this without deleting and recreating that relationship? Like some sort of advanced, more efficient SET command that changes the origin of the relationship?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.