[SERVER-83529] Generate covered projections with $expr Created: 22/Nov/23 Updated: 12/Dec/23 Resolved: 23/Nov/23 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Ivan Fefer | Assignee: | Backlog - Query Optimization |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||
| Assigned Teams: |
Query Optimization
|
||||||||||||||||
| Participants: | |||||||||||||||||
| Description |
|
if we are using $expr, we don’t produce covered projections. If index on a is present, This will have fetch + projection simple But this will have projection covered: It looks like a problem with dependency analysis of $expr that can’t determine that we only need field “a” that can come from the index. In some cases we have to use $expr syntax. For example, in $lookup with pipelines. |
| Comments |
| Comment by Ivan Fefer [ 23/Nov/23 ] |
|
Closing this as a duplicate |