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

$group using index

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor - P4
    • Resolution: Duplicate
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Aggregation Framework
    • Labels:
      None

      Description

      It would be great for a $group stage to use indexes for easy group.

      For example, this aggregation

      [
      {
          $group: {
              _id: "$media",
              count: {$sum:1}
          }
      },
      {
          $sort: {
              count: 1
          }
      },
      {
          $limit: 10
      }
      ]
      

      is not using the "media" index.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned
              Reporter:
              bappr Benjamin Appréderisse
              Participants:
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: