neo4j中基于两个节点的顺序
在neo4j中,我想根据ContactId和LookedupStatus按降序排列结果 此查询仅基于ContactId对结果进行排序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)您可以组
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