Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/neo4j/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
neo4j中基于两个节点的顺序_Neo4j_Cypher - Fatal编程技术网

neo4j中基于两个节点的顺序

neo4j中基于两个节点的顺序,neo4j,cypher,Neo4j,Cypher,在neo4j中,我想根据ContactId和LookedupStatus按降序排列结果 此查询仅基于ContactId对结果进行排序 MATCH (p:Contact)<-[:RELATIONSHIP]-(d:GroupMember) WHERE toint(d.GroupId) = 55 and p.EmailId<>'' RETURN p order by toint(p.ContactId) desc 匹配(p:Contact)您可以组

在neo4j中,我想根据ContactId和LookedupStatus按降序排列结果

此查询仅基于ContactId对结果进行排序

   MATCH (p:Contact)<-[:RELATIONSHIP]-(d:GroupMember) 
   WHERE toint(d.GroupId) = 55 
   and p.EmailId<>''
   RETURN p
   order by toint(p.ContactId) desc

匹配(p:Contact)您可以组合排序条件:

UNWIND [ {a:3, b:2, c: 1}, {a:1, b:2, c: 2}, 
         {a:1, b:1, c: 3}, {a:3, b:1, c: 4} ] as n
RETURN n ORDER BY n.a DESC, 
                  n.b ASC

您可以组合排序条件:

UNWIND [ {a:3, b:2, c: 1}, {a:1, b:2, c: 2}, 
         {a:1, b:1, c: 3}, {a:3, b:1, c: 4} ] as n
RETURN n ORDER BY n.a DESC, 
                  n.b ASC