I am trying to sort a field on a collection in mongo, here is the query,
db.results.find({}).sort({'date':1})
got an error:
Sort operation used more than the maximum 33554432 bytes of RAM
I tried to create an index,
db.results.createIndex({'date':1})
and then executed the above sort
, got an error in Robomongo 0.9.0
,
The specified text was not found
How to conduct the sort properly and also how to get a ISO date range from the field date
in this case.
ps a sample dates
2017-06-29 00:00:00.000Z
2017-06-27 00:00:00.000Z
2017-06-28 00:00:00.000Z
2017-06-30 00:00:00.000Z