X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (mx1.hub.org [200.46.208.251]) by postgresql.org (Postfix) with ESMTP id F268F9FA12F for ; Thu, 1 Jun 2006 22:19:31 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.208.251]) (amavisd-new, port 10024) with ESMTP id 92781-03 for ; Thu, 1 Jun 2006 22:19:26 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey- Received: from ug-out-1314.google.com (ug-out-1314.google.com [66.249.92.168]) by postgresql.org (Postfix) with ESMTP id 034B89FA040 for ; Thu, 1 Jun 2006 22:19:26 -0300 (ADT) Received: by ug-out-1314.google.com with SMTP id a2so306720ugf for ; Thu, 01 Jun 2006 18:19:25 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=L5iDZBwYGOeRAQmmKKt0swcAdzX2R5pNt9fsKqwFLVeaamkZFaJbeqowoQUJzTjZy+8/EV56v8mszGXU6tvrORvL3uuRAiNBE2+mv0teq2EzonKw/sj3K4/HHgOHiGw1y9/exy3HW3BOYfySsISBjADAXMEsJ078zFQE16U3Hzg= Received: by 10.67.97.7 with SMTP id z7mr292309ugl; Thu, 01 Jun 2006 18:19:25 -0700 (PDT) Received: by 10.67.27.9 with HTTP; Thu, 1 Jun 2006 18:19:25 -0700 (PDT) Message-ID: <12b7ac1e0606011819k483760fbq910f4fcf9dcf7762@mail.gmail.com> Date: Fri, 2 Jun 2006 13:19:25 +1200 From: "David Clarke" To: pgsql-sql@postgresql.org Subject: Re: Table design question In-Reply-To: <20060601234424.GB1610@clueinc.net> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <12b7ac1e0606010405u6e062f71mf4adbaeb6c46df5f@mail.gmail.com> <60r728sl9r.fsf@dba2.int.libertyrms.com> <20060601234424.GB1610@clueinc.net> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200606/34 X-Sequence-Number: 25270 On 6/2/06, postgres@jal.org wrote: > On Thu, 01 Jun 2006, Chris Browne wrote: > > > Celko is decidedly *NOT* promoting the notion that you should use a > > 100 byte long "natural key." > > > > Jamie's comments of "Orthodox versus Reform" seem reasonably > > appropriate in outlining something of the difference between the > > positions. > > Just to be clear, that was all I was trying to do. I probably should > have mentioned that any attempt to use such an attribute as a PK should > be met with a baseball bat or other shillelagh-ish implement, but was > interrupted several times during that email drafting. > > > I may not care for doing this; you may not either; a company that > > builds auto parts that they want to sell into the automotive industry > > may care about standardizing their part IDs quite a lot. > > This is another important point. In some situations, a rigid data model > can be a godsend to coders. If you happen to sit in such an enviable > position, I would encourage you to take advantage of it. (This doesn't > mean picking bad keys, of course.) > > None of this should be taken as bashing Celko - he's a smart man and an > excellent source of advice. > > -j > Thanks everyone who replied (and also for the insightful and measured responses, not every news group is so lucky). I had progressed down the path of the serial id column but re-reading Celko's book - he spends some pages railing against "proprietary auto-numbering features" - I wanted to feel confident I was making the right choice. Thanks again Dave