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

GeoSpatial: index '2d' failure

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 1.3.3
    • Affects Version/s: 1.3.3
    • Component/s: Index Maintenance
    • None
    • Environment:
      OSX

      When indexing an array field for lat/long:

      { location : [70, -70] }

      for a collection, it will error out if not all objects in the collection have the location array populated. So, if you have 10 objects and 1 does not have a lat/long, it will error out.

      Here is the console output:

      > db.hotels.ensureIndex(

      {location : '2d'}

      )
      geo field[location] has to be an Object or Array

      It seems like this should not error out, but rather skip over the ones that are not populated.

            Assignee:
            eliot Eliot Horowitz (Inactive)
            Reporter:
            revans Robert Evans
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: