I worked around this bug by first calling "$unset" with {"":1} but now
we have a guarantee of 2 operations per save, whereas $unset was
conditional in my first implementation.
-Aaron
> --
> You received this message because you are subscribed to the Google Groups
> "mongodb-user" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/mongodb-user/-/BjEPUjlYBNUJ.
> To post to this group, send email to mongod...@googlegroups.com.
> To unsubscribe from this group, send email to
> mongodb-user...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/mongodb-user?hl=en.
--
Aaron Westendorf
Senior Software Engineer
Agora Games
359 Broadway
Troy, NY 12180
Phone: 518.268.1000
aa...@agoragames.com
www.agoragames.com
If you look at the bson spec you will see this is a valid field name.
http://bsonspec.org/#/specification
There are many use-cases where "" can be used as a field name but
unfortunately update doesn't support this.
If you look at the bson spec you will see this is a valid field name.
http://bsonspec.org/#/specification
Yes, that is fixed in 2.1.0 so you won't get that error.
>> If you look at the bson spec you will see this is a valid field name.
>> http://bsonspec.org/#/specification
>
>
> Well, not all BSON documents are actually legal to store (eg. "." in key
> names).
Correct, and we try to keep that down to a minimum. The dot is really
a soft-limit as it just causes problems with queries/indexing. From
the server's point of view it doesn't really matter as long as you
don't reach into that field with some query/expression. We have found
it much easier for users/clients to simply not introduce this
confusion by disallowing it at that level.
> --
> Glenn Maynard