mongodb - Pymongo cursor returns incomplete results -


i have 2 following scenarios using pymongo:

cursor = db.col.find({'_id':{'$in':list_of_ids}})

returns 87 records, while list_of_ids 335 in length.

stuff = [] item in list_of_ids:         stuff.append(list(db.col.find({'_id':item}) 

returns of 335. don't want hit db 335 times, need records. couldn't find in documentation. exhaust cursor seems nice couldn't figure how set it. next() method iterates 1 one. list(cursor) still returns 87.

does have suggestions?


Comments

Popular posts from this blog

javascript - Thinglink image not visible until browser resize -

firebird - Error "invalid transaction handle (expecting explicit transaction start)" executing script from Delphi -

mongodb - How to keep track of users making Stripe Payments -