X-Original-To: pgsql-performance@postgresql.org Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id 80A6F47644F for ; Wed, 14 May 2003 22:10:03 -0400 (EDT) Received: from postgresql.org ([64.49.215.8]) by localhost (postgresql.org [64.49.215.8:10024]) (amavisd-new) with ESMTP id 89838-09 for ; Wed, 14 May 2003 22:10:02 -0400 (EDT) Received: from water.oasis.net.au (water.oasis.net.au [210.8.139.2]) by postgresql.org (Postfix) with ESMTP id 39BE8475F16 for ; Wed, 14 May 2003 22:10:01 -0400 (EDT) Received: from oasis.net.au (guardian [210.8.139.5]) by water.oasis.net.au (8.9.3/8.9.3/Debian 8.9.3-21) with ESMTP id MAA17960; Thu, 15 May 2003 12:19:23 +1000 X-Authentication-Warning: water.oasis.net.au: Host guardian [210.8.139.5] claimed to be oasis.net.au Message-ID: <3EC2F81B.10001@oasis.net.au> Date: Thu, 15 May 2003 12:14:51 +1000 From: Rudi Starcevic User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.3) Gecko/20030312 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Rudi Starcevic Cc: Victor Yegorov , Stephan Szabo , Postgres Performance Subject: Re: constraint with reference to the same table References: <20030514181136.S52444-100000@megazone23.bigpanda.com> <3EC2F1E4.8080706@oasis.net.au> <20030515015811.GE1549@nordlb.lv> <3EC2F65F.2050004@oasis.net.au> In-Reply-To: <3EC2F65F.2050004@oasis.net.au> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new X-Archive-Number: 200305/172 X-Sequence-Number: 1951 Perhaps I also need a 3rd Index ? One for Business's One for People and One for Business_People. I think I may need the 3rd Index for query's like Select b_id From business_people where b_id = 1 and pn_id = 2; I think this way I have an Index for 3 type's of queries. When I looking for data on just the business, when I'm looking for data on just people and when I'm looking for data on business people relationships. Cheers Rudi.