Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-53977

Allow rewrite to produce only empty documents in $unpackBucket if it is followed by $count

    XMLWordPrintableJSON

Details

    • Task
    • Status: Closed
    • Major - P3
    • Resolution: Fixed
    • None
    • 4.9.0
    • Querying
    • Fully Compatible
    • Query 2021-01-25, Query Optimization 2021-02-22, Query Optimization 2021-03-08, Query Optimization 2021-03-22

    Description

      We can achieve this by changing the arguments to:

      {include: []}

      This should be done inside $unpackBucket's doOptimizeAt() and coordinated with the rest of the code being called from there.

      Attachments

        Issue Links

          Activity

            People

              svilen.mihaylov@mongodb.com Svilen Mihaylov
              jacob.evans@mongodb.com Jacob Evans
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: