-
Type: Bug
-
Resolution: Done
-
Priority: Major - P3
-
Affects Version/s: 2.2.3
-
Component/s: Querying
-
Fully Compatible
-
OS X
-
If you're doing a query with exists, it will not use the index. SERVER-393 was supposed to fix this afaik, but it is still forcing queries to not use the index, even if there is a more suitable one (including the exists field). If I use $hint to force it to use an index, then it just ignores the $exists.
Additionally, if I use $hint, then the documents returned do NOT contain that field even if they should've. It's like I added a projection with that field being excluded. This might be a different bug though.
See steps to reproduce for a test case.
- depends on
-
SERVER-11446 don't punt all not/nor to collscan.
- Closed
- related to
-
SERVER-10005 $exists:false prevents use of a sparse index on a different field
- Closed