How could I write aggregation without exceeds maximum document size?

前端 未结 3 1881
感动是毒
感动是毒 2020-12-10 05:51

I got exceeds maximum document size problem exception by the query as follows,

pipe = [
    {\"$match\": { \"birthday\":{\"$gte\":datetime.datet         


        
3条回答
  •  醉梦人生
    2020-12-10 06:08

    As @Frederick said requires mongo 2.6 at least, For further reference, here is the link from mongo documentation, which works similar to runCommand way but with db.collection.aggreagate, note that for document limit use "cursor" option, for sort limit use "allowDiskUse" option.

提交回复
热议问题