When I try saving a dict with a '.' in the key PyMongo throws an error (InvaildName) however I do see (on the Mongodb website) that keys can have '.''s in them. Why is it that pymongo won't let me save these docs? Is there an issue with them and Mongo?
James
Where are you seeing an example of documents with "." in a key name? Those are invalid in MongoDB (hence PyMongo's restriction).
The reasoning is that we use dot notation in queries to reach inside of embedded documents.
You can use the dot in updates and finds, but not in save/insert.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With