From: | Gevik Babakhani <pgdev(at)xs4all(dot)nl> |
---|---|
To: | Andreas Pflug <pgadmin(at)pse-consulting(dot)de> |
Cc: | pgsql-patches <pgsql-patches(at)postgresql(dot)org> |
Subject: | Re: Patch for UUID datatype (beta) |
Date: | 2006-09-18 08:41:38 |
Message-ID: | 1158568898.19958.14.camel@voyager.truesoftware.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-patches |
On Mon, 2006-09-18 at 09:21 +0200, Andreas Pflug wrote:
> Gevik Babakhani wrote:
> > - new_guid() function is supported. This function is based on V4 random
> > uuid value. It generated 16 random bytes with uuid 'variant' and
> > 'version'. It is not guaranteed to produce unique values
>
> Isn't guaranteed uniqueness the very attribute that's expected? AFAIK
> there's a commonly accepted algorithm providing this.
>
uniqueness is never a guaranteed. that is according to the RFC docs.
However the new_guid() generates a random value in the range of 256^256.
The random value is again based on the PG's randomizer which is a very
good one.
uniqueness is never a guaranteed in the sense that there is a tiny
chance someone of the other side of the planet might generate the same
guid. Or if you set your PC's clock back to the past (1981) you have a
tiny chance to generate a same guid twice.
I am running a test that is going on for the past two days, in has
generated over 14 million guids with new_guid() and yet no
duplicates :)
Regards,
Gevik
> Regards,
> Andreas
>
>
From | Date | Subject | |
---|---|---|---|
Next Message | Gevik Babakhani | 2006-09-18 08:46:00 | Re: UUID/GUID discussion leading to request for hexstring bytea? |
Previous Message | Teodor Sigaev | 2006-09-18 08:21:23 | Re: Release notes |
From | Date | Subject | |
---|---|---|---|
Next Message | Harald Armin Massa | 2006-09-18 09:11:04 | Re: Patch for UUID datatype (beta) |
Previous Message | Andreas Pflug | 2006-09-18 07:21:37 | Re: Patch for UUID datatype (beta) |