Hi,
I'm trying to do a MapReduce based on a query that looks something
like this:
query : {'ll' : {'$near': [40.702,-73.990], '$maxDistance': .01}}
The problem is that it seems $near has a default of 100 results (as
described here:
http://www.mongodb.org/display/DOCS/Geospatial+Indexing#GeospatialIndexing-Querying)
When I execute the mapreduce, this limit is confirmed in the dbres
("counts":{"input":100,"emit":100,"output":4})
For a normal query, the documentation says to change the limit for a
$near query using dot notation find({'ll' : {'$near':
[40.702,-73.990], '$maxDistance': .01}}).limit(20). But how do we do
that with a map reduce? We can't simply append .limit() to the object
in the mapreduce command object (at least I get an error), and the
'limit' parameter of the mapreduce command has no effect on the $near
query.
So how do we get around the 100 limit for $near with a mapreduce?