Hello,
I found there is a flaw of apoc procedure call apoc.meta.data()
.
I used the example dataset:
cineasts_12k_movies_50k_actors.tgz (14MB).
When I execute call apoc.meta.data()
,
For the relationship "RATED", it only records one label "User".
Then when I execute
match (x:User)-[r:RATED]->(y:Movie) where labels(x)=["User"] return r
, the result is (no changes, no records)
.Then I execute
match (x:User)-[r:RATED]->(y:Movie) return labels(x),r
, there are many results like:
labels(x) | r |
---|---|
["Person", "User"] | { "stars": 5 } |
Hence, there are two labels of the source in the "RATED" relationship.
Then, I execute match (x:User)-[r:RATED]->(y:Movie) where labels(x)=["Person","User"] return r
, the result is correct.
But when I execute match (x:User)-[r:RATED]->(y:Movie) where labels(x)=["User","Person"] return r
, the result is (no changes, no records)
.
Hence, there are mainly two problems of my post:
- Why does
call apoc.meta.data()
procedure not provide full labels of the source in the relationship "RATED"? - Is there any method to ignore the order of labels in the
where
clause?
Thank you!