【问题标题】:START Cypher query relationship lookupSTART Cypher 查询关系查找
【发布时间】:2014-06-14 13:53:13
【问题描述】:

我有以下类型的 Cypher Neo4J 查询:

START rel=relationship:relationship_auto_index(user="9d6e7140-f3c3-11e3-927f-1f5ca4210ac7") 
RETURN rel;

您知道我如何过滤以仅返回具有 :TO 标签的 rels 吗?我知道我可以这样做,但我需要使用遗留索引并希望过滤我得到的关系。谢谢!

【问题讨论】:

    标签: neo4j cypher


    【解决方案1】:

    Cypher 有一个TYPE 函数:

    START rel=relationship:relationship_auto_index(user="9d6e7140-f3c3-11e3-927f-1f5ca4210ac7") 
    WHERE TYPE(rel)='TO'
    RETURN rel;
    

    注意省略 TO 前面的冒号,因为它不是关系类型本身的一部分。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-09-16
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多