I am using pymongo for programming.
I want to update a field from an embedded document from an array which is stored in the MongoDB database. I can update it directly from the mongo shell by using the dot (.)
operator like
Ex:
db.coll.update({},{"year.0.month":5})
But if I use the same year.0.month
in pymongo, I am unable to update it as it giving me an error.
Can someone please elaborate how can I achieve this in pymongo?