[SERVER-8560] Covered query on a compound index that does not yield any results does not have indexOnly = true Created: 13/Feb/13 Updated: 15/Feb/13 Resolved: 13/Feb/13 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Sridhar Nanjundeswaran | Assignee: | Unassigned |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
2.4.0-rc0 on OS X |
||
| Operating System: | ALL |
| Steps To Reproduce: |
var coll = db.getCollection("covered_compound_1") ) ) ).hint( {a:1, b:-1, c:1}).explain() |
| Participants: |
| Description |
|
Covered index query which does not return a result does not have indexOnly=true |
| Comments |
| Comment by Sridhar Nanjundeswaran [ 13/Feb/13 ] |
|
Resolving this ticket. Adding the projection sets the flag correctly |
| Comment by Aaron Staple [ 13/Feb/13 ] |
|
I think you need a projection spec here that excludes _id. |