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

sort query results by distance to a point

    XMLWordPrintable

Details

    • New Feature
    • Status: Backlog
    • Minor - P4
    • Resolution: Unresolved
    • None
    • None
    • Geo, Index Maintenance, Querying
    • None

    Description

      Would be nice to be able to sort the results of a geo query according to their distance to another point. Syntax would be something like:
      db.foo.find(...).sort({loc : {$near : [lat,long]}})

      Attachments

        Issue Links

          Activity

            People

              backlog-query-optimization Backlog - Query Optimization
              matulef Kevin Matulef
              Votes:
              4 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated: