Re: Question about uuid_generate_v3
| От | Adrian Klaver |
|---|---|
| Тема | Re: Question about uuid_generate_v3 |
| Дата | |
| Msg-id | 201107230931.30741.adrian.klaver@gmail.com обсуждение |
| Ответ на | Question about uuid_generate_v3 (Godofredo Contreras <gcontreras@infraestructuragis.com>) |
| Ответы |
Re: Question about uuid_generate_v3
|
| Список | 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.klaver@gmail.com
В списке pgsql-general по дате отправления: