MATCH (keanu:Person)-[:ACTED_IN]->()<-[:ACTED_IN]-(c), (c)-[:ACTED_IN]->()<-[:ACTED_IN]-(coc)
Without anything else, couldnt all the above indicated nodes be the same node? In other words, "keanu", "c"and "coc" could all refer to Keanu Reeves, for example. Is this correct?
Also, if we specified the following:
MATCH (keanu:Person)-[:ACTED_IN]->()<-[:ACTED_IN]-(c), (c)-[:ACTED_IN]->()<-[:ACTED_IN]-(coc)
WHERE keanu <> c
All we would be guaranteeing is that keanu and c are not equal, so therefore coc and keanu could be right? On that note, wouldnt the following also have a similar reasoning:
MATCH (keanu:Person)-[:ACTED_IN]->()<-[:ACTED_IN]-(c), (c)-[:ACTED_IN]->()<-[:ACTED_IN]-(coc)
WHERE keanu <> coc
Only keanu and coc are not equal, but keanu and c could be equal.
Couldn't the same be said about this query below, in that coActor could refer to keanu?
MATCH (keanu:Person)-[:ACTED_IN]->(movie:Movie),
(coActor:Person)-[:ACTED_IN]->(movie)
WHERE keanu.name = 'Keanu Reeves'
RETURN DISTINCT coActor.name;