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.
Cypher 在匹配关系中支持 OR(|) 我想要这样的 Cypher query= ' start n= node:node_auto_index(name=ashish '') MATCH n-[?: f&:t]-> k return k '
Cypher 支持这一个 n-[?:f|:t]->k for 2 关系,就像这样 G -[:f]->k <-[:t]-H 但是 mote than 2 关系呢?说 3,4 等
您只需将它们列为单独的 MATCH 元素
start n=node:node_auto_index(name='ashish') MATCH n-[:f]-> k, n-[:t]-> k, n-[:g]-> k return k
您可以像这样分开几个匹配语句:
MATCH n-[:A_REL_TYPE*]-end, n-[:ANOTHER_REL_TYPE*]-end