Re: Avoiding surrogate keys - Mailing list pgsql-general

From Mark Watson
Subject Re: Avoiding surrogate keys
Date
Msg-id 6E83A4C5A97B4943B3ABBD82782CC8D4@Gateway
Whole thread Raw
In response to Re: Avoiding surrogate keys  (Martin Gainty <mgainty@hotmail.com>)
List pgsql-general
I agree, as long as one needs the country names in only one language.
-Mark
(Sorry Martin- forgot to "Reply to all" the last time)
________________________________________
De : pgsql-general-owner@postgresql.org
[mailto:pgsql-general-owner@postgresql.org] De la part de Martin Gainty
Envoyé : 21 avril 2010 16:38 À : wmoran@potentialtech.com Cc :
pgsql-general@postgresql.org Objet : Re: [GENERAL] Avoiding surrogate keys

...

static information such as country names *should be* de-normalised into
non-indexed columns of the driving table as you have already done

if on the other hand the column information country names were changing were
dynamic then you would want to keep them in their respective table

as country code 001 will always be US (and the remaining countries and
country code will never change) i would suggest keeping the full name in the
driving table (same goes with state/province data btw)

...




pgsql-general by date:

Previous
From: Martin Gainty
Date:
Subject: Re: Avoiding surrogate keys
Next
From: Tom Lane
Date:
Subject: Re: Returning a char from a C-language function