Multiple MATCH statement freezes Neo4j Browser

Using Neo4j Desktop 1.4.5, DBMSs 4.2.4, Browser 4.2.6

I want to MATCH and return <120 nodes with the following statement:

MATCH (n:Score) MATCH (m:Component) MATCH (o:Interface) MATCH (p:Step) RETURN n, m, o, p

When I run, the Browser window turns grey and freezes. I can return each of the node labels independently and I done another MATCH which returned 300 of 55,000 Message nodes, so not sure why a statement with less than 120 nodes is causing this problem. Is there a limit on the number of MATCH statements I can have or return?


Your statement will result in a cartesian join and so of there are 100 :Score nodes, 40 :Component nodes, 20 :Interface nodes and 30 :Step nodes then the result will be

100 x 40 x 20 x 30

If you simply want browser to return all :Score, all :Component , all :Interface and all :Step nodes then use

match (n) where 
     labels(n)=["Score"] or 
     labels(n)=["Component"] or
     labels(n)=["Interface"] or
return n;
1 Like

Thank you, that was it.

1 Like