Re: Surrogate keys

Поиск
Список
Период
Сортировка
От Chris Browne
Тема Re: Surrogate keys
Дата
Msg-id 60oe28mdfx.fsf@dba2.int.libertyrms.com
обсуждение исходный текст
Ответ на Re: Surrogate keys (Was: enums)  ("Pollard, Mike" <mpollard@cincom.com>)
Список pgsql-hackers
mark@mark.mielke.cc writes:

> On Thu, Jan 19, 2006 at 09:37:12AM -0500, Pollard, Mike wrote:
>> Martijn van Oosterhout wrote:
>> > Please provides natural keys for any of the following:
>> > - A Person
>> > - A phone call: (from,to,date,time,duration) is not enough
>> > - A physical address
>> > - A phone line: (phone numbers arn't unique over time)
>> > - An internet account: (usernames not unique over time either)
>> Ahh, a challenge.  Hmm, not sure about all of them, but here goes:
>> A Person - well, you could use a bit map of their fingerprints, or maybe
>> their retinal scan.  Of course, that could change due to serious injury.
>> Maybe some kind of representation of their DNA?
>
> Yes. Representation of the DNA is probably best. But - that's a lot of
> data to use as a key in multiple tables. :-)

That is arguably about the best choice possible, for a human being, as
DNA isn't supposed to be able to change (much).  

Mind you, there do exist odd cases where a person might have two sets
of DNA in different parts of their body.  This commonly (well, it's
not really very common...) happens when non-identical twins share a
blood supply; that twins were involved may not be noticed if one does
not survive to birth...

>> A physical address - how about longitude/latitude/height from sea level?
>
> Planet? Solar system? Galaxy? Universe? :-)
>
> I agreed with what you had to say (the stuff I deleted). Just felt
> like being funny. Not sure if I'm successful. Hehe...

Well, that's useful for representing a key for a piece of real estate.

It's fairly interestingly useless for representing a human attribute,
at least in terms of being a primary key...
-- 
output = ("cbbrowne" "@" "acm.org")
http://cbbrowne.com/info/linux.html
"It's a pretty rare beginner who isn't clueless.  If beginners weren't
clueless, the infamous Unix learning cliff wouldn't be a problem."
-- david parsons


В списке pgsql-hackers по дате отправления:

Предыдущее
От: "Joshua D. Drake"
Дата:
Сообщение: Re: 8.0.5 Bug in unique indexes?
Следующее
От: "Michael Paesold"
Дата:
Сообщение: Re: 8.0.5 Bug in unique indexes?