If all dependencies of $expr are provided by an index, don't generate FETCH

    • Type: Improvement
    • Resolution: Unresolved
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Query Optimization
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Currently there is no way to cover an query with $expr with an index. Even if all dependencies of $expr are provided by the index, we will still generate a FETCH stage to evaluate the $expr.

      Currently QuerySolutionNode for IndexScan fully supports having a filter MatchExpression.

      We should try to attach $expr to IndexScan nodes instead of generating FETCH, if it is possible. 

            Assignee:
            Unassigned
            Reporter:
            Ivan Fefer
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: