'Unsupported projection option $in in pymongo

I tried to use something like this in pymongo:

list(db[collectionName].find({}, {fieldName: {"$in": [value1, value2]}}))

but I get an error that its unsupported projection option. How can I correct it?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source