Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在使用 Java 并想检查两个节点之间是否存在关系,如果存在则检索边缘权重。有没有办法在一个数据库调用中做到这一点?谢谢
在这种情况下,“可变长度匹配” r 成为 rel 的集合,而不是通常的单一关系。
start n1=node(1), n2=node(2) match shortestPath(n1-[r*]-n2) return extract(rel in r : r.weight)