I have created 5 nodes in neo4j as follows.
Node 1 {userid:1000, username: A, someOtherProperties...}
Node 2 {userid:2000, username: B, someOtherProperties...}
Node 3 {userid:3000, username: c, someOtherProperties...}
Node 4 {userid:4000, username: D, someOtherProperties...}
Node 5 {userid:5000, username: E, someOtherProperties...}
Node 1 connected with Node 2 & 3, and Node 2 connected with node 1, 3, 4
1 -> 2
1 -> 3
2 -> 1
2 -> 3
2 -> 4
3 -> 4
Now I want user suggestion for node 1 which contain those node which is not connected with it self with mutual count. I want result like this.
node id userid username mutual count
------- ------ -------- -------------
4 4000 D 2 (which is node 2 & 3)
5 5000 E 0
I had tried cypher query, but I didn't get success.