From: | Adrian Klaver <adrian(dot)klaver(at)gmail(dot)com> |
---|---|
To: | pgsql-general(at)postgresql(dot)org |
Cc: | Godofredo Contreras <gcontreras(at)infraestructuragis(dot)com> |
Subject: | Re: Question about uuid_generate_v3 |
Date: | 2011-07-23 16:31:30 |
Message-ID: | 201107230931.30741.adrian.klaver@gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Saturday, July 23, 2011 8:39:52 am Godofredo Contreras wrote:
> Hi,
>
> First of all, I am new to this list and I'm not sure if it is the
> correct one to post technical questions. If it is not please tell me
> which one I should use.
>
> Recently I installed postgresql 9.1beta3 on a Windows 7 machine to start
> testing uuid generation. I correctly installed the functions in my
> public schema, however when I run the following sql sentence SELECT
> uuid_generate_v3(uuid_ns_url(), 'http://www.cit.com') I always get the
> same result "b2c61380-d1b2-3ca8-a63b-c45d4e0da06a".
>
> Not sure if this is a bug or if I am doing something wrong or if I
> missunderstood that uuid_generate_v3 should be generating differente
> uuids in every different call to the function.
>
> Has someone faced the same problem? in case of yes could you please
> share your solution with me?
From the docs http://www.postgresql.org/docs/9.0/interactive/uuid-ossp.html:
"The name parameter will be MD5-hashed, so the cleartext cannot be derived from
the generated UUID. The generation of UUIDs by this method has no random or
environment-dependent element and is therefore reproducible. "
You might want to look at one of the other functions listed at the above page.
>
> Thank you
> Godofredo Contreras
--
Adrian Klaver
adrian(dot)klaver(at)gmail(dot)com
From | Date | Subject | |
---|---|---|---|
Next Message | Chris Travers | 2011-07-23 16:47:03 | Re: Implementing "thick"/"fat" databases |
Previous Message | Yan Chunlu | 2011-07-23 16:14:51 | Re: streaming replication does not work across datacenter with 20ms latency? |