编辑:查看评论并忽略此问题
我有一个带有此代码的Neo4J插件:
enum VrtrackRelationshipTypes implements RelationshipType { created_for }
Direction in = Direction.INCOMING;
System.out.println("will get nodes created_for study with node id " + study.getId());
int count = 0;
for (Relationship slRel: study.getRelationships(VrtrackRelationshipTypes.created_for, in)) {
count++;
}
System.out.println(count);
返回:
将获取节点created_for study with node id 1453769
3445
然而,使用网络前端和一些密码:
match (n)-[:created_for]->(m) where id(m) = 1453769 return count(distinct(n))
返回:
3631
这怎么可能?
答案 0 :(得分:0)
在某处,您计算了所有关系,在另一个计算不同结束节点。
尝试运行它并查看它返回的内容:
select from (SELECT Title, $checks[0].Lastcheck as Lastcheck , $checks[0].Status as Status FROM PAGES
let $a = ( select EXPAND(page2chck) from $parent.$current),
$checks= ( select Lastcheck, Status from $a where Lastcheck in ( select max(Lastcheck) from $a))
) where Lastcheck < DATE("2016-02-03 00:00:00")