X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (neptune.hub.org [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 8E712D1B494 for ; Sun, 4 Jan 2004 07:21:54 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 42671-10 for ; Sun, 4 Jan 2004 03:21:05 -0400 (AST) Received: from relay01.kbs.net.au (relay01.kbs.net.au [203.220.32.149]) by svr1.postgresql.org (Postfix) with ESMTP id 33811D1BB71 for ; Sun, 4 Jan 2004 03:21:04 -0400 (AST) Received: from [203.221.247.184] (helo=familyhealth.com.au) by relay01.kbs.net.au with esmtp (Exim 3.36 #2) id 1Ad2ZP-00057I-00; Sun, 04 Jan 2004 18:21:07 +1100 Message-ID: <3FF7BEDD.7050208@familyhealth.com.au> Date: Sun, 04 Jan 2004 15:21:01 +0800 From: Christopher Kings-Lynne User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.6b) Gecko/20031205 Thunderbird/0.4 X-Accept-Language: en-us, en MIME-Version: 1.0 To: "D. Dante Lorenso" Cc: pgsql-performance@postgresql.org Subject: Re: Indexing a Boolean or Null column? References: <3FF769EA.7090508@lorenso.com> <3FF79764.6060805@familyhealth.com.au> <3FF7A395.4050106@lorenso.com> In-Reply-To: <3FF7A395.4050106@lorenso.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200401/20 X-Sequence-Number: 5195 > In this case, it WILL pay off to have the index on a boolean > column, yes? Will I win my debate with my collegue? ;-) > > I think Tom Lanes suggestion of partial indexes is what I need to > look into. Yes, given that it will be highly skewed towards false entries, Tom's suggestion is perfect. Chris