So here is my query in my repo
When I haveCode:@Query("start user=node({0}) " + "match user-[:FRIEND]-friends-[:FRIEND]-friendsOfFriends, " + "user-[r?:FRIEND]-friendOfFriends " + "where r IS NULL " + "return friendsOfFriends " + "order by friendsOfFriends.lastName asc") public Page<User> findFriendsOfFriends(Long userId, Pageable pageable);
"user-[r?:FRIEND]-friendOfFriends " +
"where r IS NULL " +
I am not getting results back. I am expecting this to filter out friends of friends that are already friends of mine. But instead it ends up filtering everyone out, when it shouldn't.
If I remove that part, then I get a list of all my friends of friends including ones that are already friends of mine.
So I figure I did something wrong in that part, but can't figure out what. And if I am pretty sure that I tried that query in the shell and it worked as expected. But I can't be positive again.
Thanks
Mark


Reply With Quote