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

scan and order always loads the full document

    • Type: Icon: Improvement Improvement
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: Querying
    • None

      This has come up a few times recently - when we scan and order a doc we always load the full doc rather than sorting based on index keys when possible. There may be some concurrency related issues to deal with if we want to change this behavior, since I believe right now the full doc is kept in the result set and never re-read. One thing we could probably do pretty easily is check if a doc will fit within the sort limit (at the current point of an index scan) using index keys and then only load the doc if it does in fact look like it will fit.

            Assignee:
            david.storch@mongodb.com David Storch
            Reporter:
            aaron Aaron Staple
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: