Simplify plans for covered projections with expressions

XMLWordPrintableJSON

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

      Currently, SBE plan for query

      > db.c.createIndex({a:1, b: 1})
      > db.c.find({a: {$gt: 3}}, {_id: 0, a: 1, c: {$add: ["$a", "$b"]}}).explain()
      

      Will create an intermediate object, then extract values for fields a and b, compute expression and create final object. We can skip intermediate object and compute expressions directly using slots from index scan. Same strategy is applied for inclusion projections inĀ SERVER-54745.

            Assignee:
            [DO NOT USE] Backlog - Query Execution
            Reporter:
            Nikita Lapkov (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: