ruby - Mongoid querys memory limit -
i have around 1 million records in database. when do:
mymodel.distinct(:my_field)
getting error -
failed error 17217: "exception: distinct big, 16mb cap"
tried via aggregation - getting same error.
group = {"$group" => {"_id" => {"my_field" => "$my_field"}}} mymodel.collection.aggregate(group) failed error 16389: "exception: aggregation result exceeds maximum document size (16mb)"
is there way in mongoid increase memory limit 16mb 100mb? or other ways of getting distinct results? or how manage large queries mongoid?
Comments
Post a Comment