neography/neo4j将关系端点更改为另一个节点 [英] neography / neo4j change relationship end point to another node
本文介绍了neography/neo4j将关系端点更改为另一个节点的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在使用neography作为Neo4j图形数据库的REST api的包装. 我经常需要更改关系的结束节点,但是我无法使用neography来做到这一点.
i am using neography as wrapper of the REST api for Neo4j graph database. I often need to change the end node of a relationship, but i am not able to do this using neography.
当然,我可以删除该关系,然后使用新的端点节点重新创建该关系,但尚未对其进行优化.
Of course, i can delete the relation then recreate it with the new end point node, but it's not optimized.
有人遇到这个问题吗?
谢谢.
推荐答案
Neo4j does not allow replacing the nodes of a relationship (see javadoc). So you only can create a new relationship to the new end node and delete the other relationship.
这篇关于neography/neo4j将关系端点更改为另一个节点的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文