[SERVER-689] GeoSpatial: index '2d' failure Created: 01/Mar/10  Updated: 12/Jul/16  Resolved: 01/Mar/10

Status: Closed
Project: Core Server
Component/s: Index Maintenance
Affects Version/s: 1.3.3
Fix Version/s: 1.3.3

Type: Bug Priority: Major - P3
Reporter: Robert Evans Assignee: Eliot Horowitz (Inactive)
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

OSX


Participants:

 Description   

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.



 Comments   
Comment by Robert Evans [ 01/Mar/10 ]

Sorry about that. I'll checkout the master again and test.

Comment by Eliot Horowitz (Inactive) [ 01/Mar/10 ]

I think this ha already been fixed but hard to know since you didn't supply git hash
can you commen with the hash

Generated at Thu Feb 08 02:54:53 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.