__Affected feature__:
__AQL query (if applicable)__:
for ent in @@collection
filter ent.attr == @value
filter ent.attr == @value
filter ent.attr == @value
return ent
{ "value0": "abcd", "@collection": "Users" }
__AQL explain (if applicable)__: I can't profile or explain this query.
__Dataset__: collection with 0 or more documents
__Size of your Dataset on disk__: 0
__Replication Factor & Number of Shards (Cluster only)__: n/a
I tried with arangojs and with web interface
for ent in @@collection
filter ent.attr == @value
filter ent.attr == @value
filter ent.attr == @value
return ent
(if we have odd number > 1 of filter ent.attr == @value, throws error)
__Problem__:
error
Query: AQL: missing variable #2 (1) for node #6 (FilterNode) while planning registers (exception location: C:\vm02-windows\oskar\work\ArangoDB\arangod\Aql\RegisterPlan.cpp:372). Please report this error to arangodb.com (while optimizing plan) (exception location: C:\vm02-windows\oskar\work\ArangoDB\arangod\RestHandler\RestCursorHandler.cpp:298). Please report this error to arangodb.com
__Expected result__:
no error, return results
Hi @Tnifey,
I reproduced this in 3.7.devel and 3.6.3-1. It does not happen in 3.5.5-1.
The following queries are parsed without errors:
for ent in @@collection
filter ent.attr == @value
return ent
for ent in @@collection
filter ent.attr == @value
filter ent.attr == @value
return ent
for ent in @@collection
filter ent.attr == @value
filter ent.attr == @value
filter ent.attr == @value
filter ent.attr == @value
return ent
for ent in @@collection
filter ent.attr_1 == @value
filter ent.attr_2 == @value
filter ent.attr_3 == @value
return ent
for ent in @@collection
filter ent.attr == @value &&
ent.attr == @value &&
ent.attr == @value
return ent
The following queries raise errors:
for ent in @@collection
filter ent.attr == @value
filter ent.attr == @value
filter ent.attr == @value
return ent
for ent in @@collection
filter ent.attr == @value
filter ent.attr == @value
filter ent.attr == @value
filter ent.attr == @value
filter ent.attr == @value
return ent
for ent in @@collection
filter @value == ent.attr
filter @value == ent.attr
filter @value == ent.attr
return ent
for ent in @@collection
filter ent.attr == @value_1
filter ent.attr == @value_2
filter ent.attr == @value_3
return ent
Hi @Tnifey,
Version 3.6.4, which includes a fix for this issue, has been released.
From the Changelog:
- Fixed issue #11652: Error: AQL: missing variable #2 (1) for node #6
(FilterNode) while planning registers.
Please find the latest release in the download section.