Reputation: 33
{$and:[{
'polylineLocs': {
'$nearSphere': {
'$geometry': {
'type': 'Point',
'coordinates':
[78.02478824054135,
30.29090638871556
]
},
'$maxDistance': 250,
'$minDistance': 0
}
}
},
{'location': {
'$nearSphere': {
'$geometry': {
'type': 'Point',
'coordinates': [ 78.0009260423163,
30.266704531034748
]
},
'$maxDistance': 150,
'$minDistance': 0
}
}
}]}
I am getting this "Too many geoNear expressions" error while executing this in mongoDB. Are there any alternatives to use $and on coordinates.
Upvotes: 1
Views: 89