-------- Original Message --------
Subject: Re: [GENERAL] UUID column as pimrary key?
Date: Wed, 5 Jan 2011 10:11:49 -0700
From: Scott Ribe <scott_ribe(at)elevated-dev(dot)com>
To: Adrian Klaver <adrian(dot)klaver(at)gmail(dot)com>
On Jan 5, 2011, at 9:57 AM, Adrian Klaver wrote:
> Maybe or maybe not:)
So... If you choose to use a name-based UUID, *and* you do a bad job of
picking a name, then you have a much higher risk of collision. But it's
a pretty good bet (as in 100% of all operating systems that I know of)
that if you simply call the OS's uuid function that won't happen.
First this is one of those arguments that can go forever because
everyone is both a bit right and a bit wrong.
Second the original questions was UUID in the context of Postgres and
the UUID generation algorithm using name is one of the choices in the
So there is a likelihood that it may be used.
Third the above was a response to your assertion that the ITEF
guaranteed UUID uniqueness.
Lastly Adrians First Rule applies:
"The good will take care of itself, its the bad you have to plan for."
The problem is not if people do the right thing it is if they do the
wrong thing. As someone else upstream pointed the OP was looking to use
UUIDs as a PK and in that case the database will enforce another
"namespace" and in worst case you will need to retry with a different
UUID. That covers the bad.
pgsql-general by date
|Next:||From: Filip Rembiałkowski||Date: 2011-01-05 17:37:43|
|Subject: Re: How can I get the list of index(or other objects) which
depends on a function|
|Previous:||From: Radosław Smogura||Date: 2011-01-05 17:30:42|
|Subject: Re: UUID column as pimrary key?|