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

Adding NULL sort order configuration when using sort() queries

    • Type: Icon: New Feature New Feature
    • Resolution: Unresolved
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: Querying
    • Labels:
    • Query Optimization

      At the moment, the NULL order fetching is decided upon the sort query type (DESC,ASC).

      If the query is done on field X in a DESC order the NULLs of field X will be presented last, while in an ASC order the NULLs of field X will be presented first. I saw many requests on having the ability to decide the fetch positions of the NULLs in the ordered field.

      Can it be added as an optional flag to the query syntax with a default behavior?

            Assignee:
            backlog-query-optimization [DO NOT USE] Backlog - Query Optimization
            Reporter:
            pavel.duchovny@mongodb.com Pavel Duchovny
            Votes:
            23 Vote for this issue
            Watchers:
            32 Start watching this issue

              Created:
              Updated: