Will wrote:
> I'm trying to store the value of an ipv6 address in mongo and because
> of mongo's 64bit limitation I cannot.
Why don't you store it as string?
- -aj
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iQGUBAEBAgAGBQJN95B3AAoJEADcfz7u4AZjOgULv0/WGbn4KSQiTNWIgUdL1AFz
zvzMphvqbjVAp63KjPRO5iB4ko0jYG3eOTc9mtruTTeQPOGauGPiEscYDor1qlv8
cXdxAC8SwfzoVyN2pRgvT5rRGSD7kemXonr/Id73ajRtFnZumhGf4bU5rzOJt5I0
YmWsEha+gPy5ZS1fnlckfWOqS0dRyXzFjj2xcaaO/0QSITCx2CtqaUbTQg6czOmo
K2WXP8AMznij/2JE18fYsSEHZcJc4CKgY3LakSyCzIW20F4+6uWsOpDdjpADpBnD
XmoRjWZV4VC2knGvtp9u9cqIbcKcZD6NvIgIPoFvTVJ4Pkap12NagmhneqQWXz4A
7KvFCg2ZwHvItcvy2kYabwKI+dC/aBHVBd0wJ7I7Soksc/C6tWl1WpMxu0IAaXTM
c95RudSpEJyLYT2Rt7P4CNk/Qn8COYAzar0+vLbIRYR7nj3iEkSGtvl3e8NlHwKL
9BplgSbwzis4uxYnpDew9SfxTeFZJQw=
=JJk/
-----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.
Then store the integer value as string.
- -aj
Will Smith wrote:
> Because I need to figure out if it is within a range of Addresses.
> Storing it as a string would loose the ablity to do that.
>
> On Tue, Jun 14, 2011 at 12:46 PM, Andreas Jung <li...@zopyx.com
> <http://zopyx.com>> wrote:
>
>
>
> Will wrote:
>> I'm trying to store the value of an ipv6 address in mongo and because
>> of mongo's 64bit limitation I cannot.
>
> Why don't you store it as string?
>
> -aj
- --
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
<mailto:mongod...@googlegroups.com>.
To unsubscribe from this group, send email to
mongodb-user...@googlegroups.com
<mailto:mongodb-user%2Bunsu...@googlegroups.com>.
For more options, visit this group at
http://groups.google.com/group/mongodb-user?hl=en.
> --
> 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.
- --
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/
iQGUBAEBAgAGBQJN95QtAAoJEADcfz7u4AZjaiQLv21g6hgYml2xM6LYXMKVxH8h
D2FkVM+We5a8/aWGLcokGKaS5C+eNS2AmX6ANWgaWnr39QpN9XfieuOR7UPV4d1S
ir0Zel1qM4aWWlP6IJmlZg9AId0VUvUqTex6TbGZ9AvYB4wO5vDnb9RMXDTqYFay
uKHHa2//ZYRUoMHU39wQseGYrrQYyk1j91XWiEcU3TpKnQVL/tG8O64nB14WoLkI
u0C1QSyJAq5qKr4HQA8RcmysgQbmB9tlwp9zR4CmYRozPNdBloGKbEkwnFdw1/G5
IEAXv0I6c/w4cv5IL/ZVSiitaYt54eYtDcX9sxGQmgKwPYxhX1Y8aZkoecbRQjYU
9Cqd2Tdbqs8ffafl1a/AXHLIcwGAQP12TWoie2kbOE+XP9sLXJLnkn1yUYBF4bZU
m41PDb4AdEwSYTy2mdss3k4w77zyuNId2bCxdF8FSqhKMx0bavRYfvGnmMOyvh/s
p5vQt4BvWp5yMqF9bdcRpzYptoq5LdM=
=uf8e
-----END PGP SIGNATURE-----
D-72070 Tübingen | Produce & Publish
www.zopyx.com | www.produce-and-publish.com
- ------------------------------------------------------------------------
E-Publishing, Python, Zope & Plone development, Consulting
iQGUBAEBAgAGBQJN95QtAAoJEADcfz7u4AZjaiQLv21g6hgYml2xM6LYXMKVxH8h
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
D2FkVM+We5a8/aWGLcokGKaS5C+eNS2AmX6ANWgaWnr39QpN9XfieuOR7UPV4d1S
ir0Zel1qM4aWWlP6IJmlZg9AId0VUvUqTex6TbGZ9AvYB4wO5vDnb9RMXDTqYFay
uKHHa2//ZYRUoMHU39wQseGYrrQYyk1j91XWiEcU3TpKnQVL/tG8O64nB14WoLkI
u0C1QSyJAq5qKr4HQA8RcmysgQbmB9tlwp9zR4CmYRozPNdBloGKbEkwnFdw1/G5
IEAXv0I6c/w4cv5IL/ZVSiitaYt54eYtDcX9sxGQmgKwPYxhX1Y8aZkoecbRQjYU
9Cqd2Tdbqs8ffafl1a/AXHLIcwGAQP12TWoie2kbOE+XP9sLXJLnkn1yUYBF4bZU
m41PDb4AdEwSYTy2mdss3k4w77zyuNId2bCxdF8FSqhKMx0bavRYfvGnmMOyvh/s
p5vQt4BvWp5yMqF9bdcRpzYptoq5LdM=
=uf8e
-----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.
"\xff\x10\x20\x30\x39" < "\xff\x10\x20\x30\x40" < "\xff\x10\x20\x30\x41"
So you should be able to use string comparison just as well as integer
comparison - just convert the number you are trying to compare to a
string first. This should even work if you decide to store the number
converted to a hex encoded string but storage is less efficient.
Michael.