Before you flame, I know how to get the limit, skip or get the count from regular mongodb queries when using find command.
But when using the geoSpatial runCommand which returns distance in mongodb. This doesn’t accept skip and count parameters. Does anyone know how it can be done ?
db.runCommand({ geoNear : "users", near: [25.081398,55.177263], num: 20, distanceMultiplier: 111.194})
note: For now I’m able to get limit by passing num to the query but i want to be able to skip also for paginating.
Its a option not implemented by MongoDB Yet, I’m closing this question but not erasing since there can be some workarounds or solutions by someone smarter
https://jira.mongodb.org/browse/SERVER-3925