"projection=" doesn't work in pymongo.collection.Collection.find (pymongo 3.2.2)

From: specter119 <specter119@xxxxxxxxx>
To: mongodb-user <mongodb-user@xxxxxxxxxxxxxxxx>
Date: Fri, 29 Apr 2016 09:02:37 -0700 (PDT)
Why ads?


Python version : 2.7.11
Pymongo version : 3.2.2

As is showed in official documentation 
<https://api.mongodb.org/python/current/api/pymongo/collection.html?highlight=find#pymongo.collection.Collection.find>

projection= [list] or {dict} will limit the output of find(), but in my 
script filter always works, but projection never works, no matter a list or 
a dict.

I don’t know how to set the projection to limit the output of find(). Who 
can give me an example?


-- 
You received this message because you are subscribed to the Google Groups "mongodb-user"
group.

For other MongoDB technical support options, see: https://docs.mongodb.org/manual/support/
--- 
You received this message because you are subscribed to the Google Groups "mongodb-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mongodb-user+unsubscribe@xxxxxxxxxxxxxxxx.
To post to this group, send email to mongodb-user@xxxxxxxxxxxxxxxx.
Visit this group at https://groups.google.com/group/mongodb-user.
To view this discussion on the web visit https://groups.google.com/d/msgid/mongodb-user/73fe1c39-1f9a-47bf-b2f7-e2e49c416d6f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Why ads?