Re: Avoiding surrogate keys - Mailing list pgsql-general

From Joshua D. Drake
Subject Re: Avoiding surrogate keys
Date
Msg-id 1271877261.2857.0.camel@jd-desktop.unknown.charter.com
Whole thread Raw
In response to Re: Avoiding surrogate keys  (Bill Moran <wmoran@potentialtech.com>)
Responses Re: Avoiding surrogate keys  (Bill Moran <wmoran@potentialtech.com>)
List pgsql-general
On Wed, 2010-04-21 at 15:07 -0400, Bill Moran wrote:
> I'd use an ENUM for the status, as that's not liable to change.
>
> The only problem I see with avoiding the surrogate key for the country
> is that the table might require more disk space if a lot of the country
> names end up being very long.
>

Yeah but that isn't generally a problem now and the gain he gets from
the lack of join performance is more than worth it.

Joshua D. Drake


--
PostgreSQL.org Major Contributor
Command Prompt, Inc: http://www.commandprompt.com/ - 503.667.4564
Consulting, Training, Support, Custom Development, Engineering

pgsql-general by date:

Previous
From: Bill Moran
Date:
Subject: Re: Avoiding surrogate keys
Next
From: Rich Shepard
Date:
Subject: Re: Avoiding surrogate keys