MATCH (person:Person {id:"8796093030404"})-[:KNOWS*1..2]-(friend:Person)<-[membership:HAS_MEMBER]-(forum:Forum) WHERE membership.joinDate>1347062400000 AND not(person=friend) WITH DISTINCT friend, forum OPTIONAL MATCH (friend)<-[:HAS_CREATOR]-(post:Post)<-[:CONTAINER_OF]-(forum) WITH forum, count(post) AS postCount RETURN forum.title AS forumName, postCount ORDER BY postCount DESC, toInt(forum.id) ASC LIMIT 20;