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

Sparse Indexes (WAS: Add an "ignore missing" option to indexes)

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.7.4
    • Component/s: Indexing
    • Labels:
      None
    • Environment:
      All

      Description

      The proposal is for another index option to be added that marks an index as not including any documents with missing index values in the index. For composite indexes this would ignore any documents where all the index values are missing. I would suggest if the index values are present but set to null they probably should be included in the index.

      This would save considerable space and time when inserting into polymorphic collections where an index is only designed to affect a subset of the collection.

      This would provide a large benefit to unique indexes, allowing a unique index to be created where only a percentage of the records in a collection are eligible to participate in the index. Currently it is not apparantly possible to add a unique index to a polymorphic collection where many records do not have the field to be indexed.

        Attachments

          Activity

            People

            • Votes:
              25 Vote for this issue
              Watchers:
              18 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: