I'm having a real issue. I'm trying to do a query, limit, sort, etc. This is what I'm doing:
MyModel.find( { where: { "location":
{ "near": { "lat": "80", "lng": 80 }}
},
{ limit: 50, offset: 0, skip: 10,
sort: { "name": "asc" }
},
function(err, docs) {
var retval = docs || [];
return cb(null, retval);
});
What is the magic sauce to do limit, skip, and sort?
Any help is appreciated. Thanks