I want to store JSON CSS (http://code.google.com/p/json-css/) in my
db, but the shell won't let me.
I know that originally this feature to deny dots was not in mongo db
so is there any way to turn it off?
As far as I know any character in a field name is valid JSON, so it
sohuld be also valid BSON.
I know that the dot has a special meaning in mongodb, but I don't
think it would neccesarly mess up the db if used correctly.
It should be left for the user to decide what he wants to use as field
names and live with the councequences. A shell warning may be
appropriate though.
Daniel
D�niel Boros wrote:
> Error: uncaught exception: can't have . in field names
>
> I want to store JSON CSS (http://code.google.com/p/json-css/) in my
> db, but the shell won't let me. I know that originally this feature
> to deny dots was not in mongo db so is there any way to turn it off?
> As far as I know any character in a field name is valid JSON, so it
> sohuld be also valid BSON.
Dots are used as separators for embedded documents. If you have
keys with dots inside then escape then within your application _yourself_.
- -aj
- --
ZOPYX Limited | zopyx group
Charlottenstr. 37/1 | The full-service network for Zope & Plone
D-72070 T�bingen | Produce & Publish
www.zopyx.com | www.produce-and-publish.com
- ------------------------------------------------------------------------
E-Publishing, Python, Zope & Plone development, Consulting
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iQGUBAEBAgAGBQJO0jLrAAoJEADcfz7u4AZj3iwLwOdgZ6DO2lM42ChutlX5Xu+p
+74b9T0JG568pO6Wvr3kPSS2MrW7zXHzTVAxCdUvH0Xt6j3Jkhse4t1d0NYTN+LO
huvO/MXHniaMcKlV59XNu9F2ubqk0b6wOt+ztQ95eoxWudKjfp0puoubKjVrXhrj
wHgPR+9Cc06H3W7lJxfwlbbkbqOsy6MjHnjQo62oNIOB9FrdsICcEvEwthT8qZBG
+xhDl3G/CRNqUZW7RpLPaZpND9gq+Ly6//ff2RqhvE/hCTMCpwF6MK39fzoIvtSB
uWMPx38xpyd5GUyL0+zQdGpBxMomfuJiQPoVRWTcQHpWrDBhBe/4snW7kn0MB1av
zJWv2YxZQ/mXOyHQOXa+Wb+NMd9PALyScCo8/yIlRZpn4r0TfBR/kbb0aH4n5C4P
DCiQx9xEC0TTcHbdYEGCJneojK7UbCQbcRYE/O1tIETPrg/PS9fhEhU+1bONo3n/
McAXYFicxn08K1ylM07PhcnKz3wtIfA=
=5/4W
-----END PGP SIGNATURE-----
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Dots are used as separators for embedded documents. If you have
Dániel Boros wrote:
> Error: uncaught exception: can't have . in field names
>
> I want to store JSON CSS (http://code.google.com/p/json-css/) in my
> db, but the shell won't let me. I know that originally this feature
> to deny dots was not in mongo db so is there any way to turn it off?
> As far as I know any character in a field name is valid JSON, so it
> sohuld be also valid BSON.
keys with dots inside then escape then within your application _yourself_.
- -aj
- --
ZOPYX Limited | zopyx group
Charlottenstr. 37/1 | The full-service network for Zope & Plone
D-72070 Tübingen | Produce & Publish
www.zopyx.com | www.produce-and-publish.com
- ------------------------------------------------------------------------
E-Publishing, Python, Zope & Plone development, Consulting
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iQGUBAEBAgAGBQJO0jLrAAoJEADcfz7u4AZj3iwLwOdgZ6DO2lM42ChutlX5Xu+p
+74b9T0JG568pO6Wvr3kPSS2MrW7zXHzTVAxCdUvH0Xt6j3Jkhse4t1d0NYTN+LO
huvO/MXHniaMcKlV59XNu9F2ubqk0b6wOt+ztQ95eoxWudKjfp0puoubKjVrXhrj
wHgPR+9Cc06H3W7lJxfwlbbkbqOsy6MjHnjQo62oNIOB9FrdsICcEvEwthT8qZBG
+xhDl3G/CRNqUZW7RpLPaZpND9gq+Ly6//ff2RqhvE/hCTMCpwF6MK39fzoIvtSB
uWMPx38xpyd5GUyL0+zQdGpBxMomfuJiQPoVRWTcQHpWrDBhBe/4snW7kn0MB1av
zJWv2YxZQ/mXOyHQOXa+Wb+NMd9PALyScCo8/yIlRZpn4r0TfBR/kbb0aH4n5C4P
DCiQx9xEC0TTcHbdYEGCJneojK7UbCQbcRYE/O1tIETPrg/PS9fhEhU+1bONo3n/
McAXYFicxn08K1ylM07PhcnKz3wtIfA=
=5/4W
-----END PGP SIGNATURE-----
--
You received this message because you are subscribed to the Google Groups "mongodb-user" group.
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.
You could get around this by writing a function that substitutes the
dots for a legal character before insertion and another to convert it
back on the way out of the database.
-Tyler
> > Comment: Using GnuPG with Mozilla -http://enigmail.mozdev.org/
Sorry for the confusion.
-Tyler