-
Type:
Bug
-
Resolution: Fixed
-
Priority:
Major - P3
-
Affects Version/s: None
-
Component/s: None
-
None
-
Query Execution
-
Fully Compatible
-
ALL
-
None
-
None
-
None
-
None
-
None
-
None
-
None
If a query like the following is issued:
coll.aggregate([
...
{
$lookup: {
from: coll.getName(),
as: "z",
localField: "y.base",
foreignField: "base",
pipeline: [{$match: {base: {$gt: 3}}}],
},
},
{$unwind: "$z"},
{$project: {_id: 0, "x._id": 0, "y._id": 0, "z._id": 0}},
])
Then we have a base collection that is also a secondary collection. However, querying for the arrayness of a field in "coll" via secondary collections returns a different arrayness value than what the "main" collection knows.
- related to
-
SERVER-123929 Track arrayness through $lookup+$unwind in the dependency graph
-
- In Progress
-