2
votes

I'm a little bit puzzled to understand how my query is interpreted by ArangoDB and why simple filtering does not work as expected. Here is my query:

FOR v, e, p in 3 OUTBOUND "company/jquery" company_teams, team_contributors, committed
  OPTIONS {uniqueVertices: "global", bfs: true} 
  FILTER p.vertices[1]._key == "1055031914"
  FILTER length(p.vertices[2].parents) < 2
RETURN v._id

This query returns an empty result. However, if I leave just one filter (no matter which one), I do get result. From this I conclude that this is not a data related issue, means it's either me misunderstanding how query is executed or something else.

Thoughts, ideas?

1
With one of the filters removed and RETURN p in the last line, what result do you get? - CodeManX
This is a very interesting question, and what I see is also very interesting. Even tho I don't know how interpret it. This query returns me a graph FOR v, e, p in 3 OUTBOUND "company/jquery" company_teams, team_contributors, committed OPTIONS {uniqueVertices: "global", bfs: true} //FILTER p.vertices[1]._key == "1055031914" FILTER length(p.vertices[2].parents) < 2 RETURN p - Ivan Naumenko
This one has empty result FOR v, e, p in 3 OUTBOUND "company/jquery" company_teams, team_contributors, committed OPTIONS {uniqueVertices: "global", bfs: true} FILTER p.vertices[1]._key == "1055031914" //FILTER length(p.vertices[2].parents) < 2 RETURN p @CoDEman, you have some thought on that? - Ivan Naumenko
The arango key is dynamically created unless you specify something unique by yourself... maybe the key you are using is not present. Make sure the key exists in the collection you are using your filter. It would be best if your could provide the data your query works on as well. - Prasanna
@Prasanna, the key is present. Here is the example db dump I created in order to replicate the issue drive.google.com/open?id=1VIZFL3vcZTw5q2ur-FzZQNrAa1u1jYXx - Ivan Naumenko

1 Answers

2
votes

Apparently this is bug, Arango team has confirmed that. Here is the Github ticket if you want to track it.