1
votes

I am using one of the neo4j practice graphs (see below) to learn cypher and running a query to search for people who both acted int and directed a movie, I'm running the following commands:

:play movie graph

MATCH (p:Person)-[a:ACTED_IN]->(m:Movie)<-[d:DIRECTED]-(p)
RETURN p,m,a,d,type(a),type(d)

I few things don't make sense:

  • for some rows in the result type(a) is not ACTED_IN but PRODUCER or WROTE etc.
  • a lot of nodes are returned which don't seem to satisfy this pattern
  • using OPTIONAL MATCH works exactly right but I don't know why?

Any help would be much appreciated

1
update: I think this is a bug as the query works as expected in the sandbox version in the browser where as I am using the desktop version - James
It is better to add the update in your question directly. Other guys will see it directly instead of looking for update in comments. - Paulin Amougou
@James Please create a new neo4j issue for what seems to be a serious bug. - cybersam

1 Answers

1
votes

As cybersam commented, this definitely looks like a bug in the compiled runtime.

If you PROFILE this you can see it's using compiled runtime; if you prefix the query with CYPHER runtime=slotted we get expected results.

I'll pass this along to the cypher team.