X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [64.117.224.193]) by svr1.postgresql.org (Postfix) with ESMTP id F0D4130DCF7 for ; Wed, 18 Jun 2003 15:10:19 +0000 (GMT) Received: from svr1.postgresql.org ([64.117.224.193]) by localhost (svr1.postgresql.org [64.117.224.193]) (amavisd-new, port 10024) with ESMTP id 67224-02 for ; Wed, 18 Jun 2003 12:10:09 -0300 (ADT) Received: from davinci.ethosmedia.com (unknown [209.10.40.251]) by svr1.postgresql.org (Postfix) with ESMTP id 15BE330DC97 for ; Wed, 18 Jun 2003 12:10:09 -0300 (ADT) Received: from [63.195.55.98] (HELO spooky) by davinci.ethosmedia.com (CommuniGate Pro SMTP 4.0.2) with ESMTP id 3131107; Wed, 18 Jun 2003 08:10:16 -0700 Content-Type: text/plain; charset="iso-8859-1" From: Josh Berkus Organization: Aglio Database Solutions To: Tm , Michael A Nachbaur , pgsql-sql@postgresql.org Subject: Re: Object-Relational table design question Date: Wed, 18 Jun 2003 08:07:12 -0700 User-Agent: KMail/1.4.3 References: <200306170857.26558.mike@nachbaur.com> <200306170923.34974.josh@agliodbs.com> <200306180920.44304.x@Vex.Net> In-Reply-To: <200306180920.44304.x@Vex.Net> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Message-Id: <200306180807.12360.josh@agliodbs.com> X-Archive-Number: 200306/215 X-Sequence-Number: 13973 Tm, > This would work though it's not very scaleable. Our current system makes > all elements of a service into what we call an 'attribute'. The > attributes are defined in a table, and attached to each account type, > and turned on or off, and twiddled with various definitions such as > term/period billing, etc. This makes it relatively easy to add new > services... just add another entry in the account attributes table, > whereas with hard coded joins above, if you add more services you're > going to have to edit all of your code where joins take place. Yeah, that's a very good approach. I use it for any client where they need to be able to add new "attributes" and services after the system is built. It also works for other things ... for example, a "skills" list for an HR database. -- Josh Berkus Aglio Database Solutions San Francisco