Re: Finding sequential records

From: "Richard Broersma" <richard(dot)broersma(at)gmail(dot)com>
To: "Steve Midgley" <science(at)misuse(dot)org>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: Finding sequential records
Date: 2008-09-30 14:02:05
Message-ID: 396486430809300702g1502d7f4o2947ab10d1f76ae0@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

On Mon, Sep 29, 2008 at 11:05 PM, Steve Midgley <science(at)misuse(dot)org> wrote:

> Any reason why using serial PK's with "compound
> natural unique indices" is better/worse than just using natural PK's?

Not really, surrogate keys will always work well so long as unwanted
duplicates are constrained. Surrogate Keys will allow as much
flexibility and versatility as is possible. However as the case of
unwanted duplicates illustrates, sometimes flexibility and versatility
is always wanted. So if flexibility and versatility is valued less
than the ability to add inflexible constraints (beyond preventing
duplicates) across multiple relationships, then using natural primary
keys becomes very attractive.

--
Regards,
Richard Broersma Jr.

Visit the Los Angeles PostgreSQL Users Group (LAPUG)
http://pugs.postgresql.org/lapug

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message az 2008-09-30 14:24:21 Re: optimizing a query over tree-like structure
Previous Message Oliveiros Cristina 2008-09-30 12:21:09 Re: optimizing a query over tree-like structure