-
Type: Bug
-
Resolution: Duplicate
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: Querying
-
None
-
Query
-
ALL
Example involves index on array of key/value structures.
db.foo.drop(); db.foo.insert({"a":[ {"k":"x", "v":"y"}, {"k":"z", "v":1} ] }) db.foo.createIndex({"a.k":1, "a.v":1},{partialFilterExpression:{"a.k":{$exists:true}}}) db.foo.explain().find({"a":{$elemMatch:{"k":"x","v":"y"}}}) // results in collection scan db.foo.explain().find({"a":{$elemMatch:{"k":"x","v":"y"}},"a.k":"x"}) // does use partial index as expected, but the redundant condition should not be necessary
- duplicates
-
SERVER-32540 Make partial index subset analysis consider $elemMatch object a subset of $exists
- Backlog