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

Projection expression to calculate distance between two points

    • Query Integration

      There should be a way to calculate distance from a given point for documents returned by any search.  An enhancement to projection language that allows calculating such a distance would be  the most flexible way to inject such a "distance" field.

      Original Description:

      The geoNear command provides the distance from the point passed to the command for each document returned. However, the fact that the only way to get this information from the database is via a non find() command makes it very cumbersome to work with the command.

      Is the clear separation of these command a design decision that emphasizes doing distance calculations on the client side, not in the database?

            Assignee:
            backlog-query-integration [DO NOT USE] Backlog - Query Integration
            Reporter:
            ajsharp Alex Sharp
            Votes:
            9 Vote for this issue
            Watchers:
            16 Start watching this issue

              Created:
              Updated: