From: Marc G. Fournier <scrappy@postgresql.org>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-sql@postgresql.org
Subject: Re: Putting an INDEX on a boolean field?
Date: Fri, 17 Jun 2005 02:04:12 -0300 (ADT)
Message-ID: <20050617020039.P90456@ganymede.hub.org> (raw)
In-Reply-To: <15887.1118983309@sss.pgh.pa.us>
References: <20050617011336.Q90456@ganymede.hub.org>
<15887.1118983309@sss.pgh.pa.us>
On Fri, 17 Jun 2005, Tom Lane wrote:
> "Marc G. Fournier" <scrappy@postgresql.org> writes:
>> Does that make sense? Would it ever get used?
>
> It could get used if one of the two values is far less frequent than the
> other. Personally I'd think about a partial index instead ...
Hrmmmm, hadn't thought of that ... wouldn't you have to build two indexes
(one for true, one for false) for this to be completely effective? unless
you know all your queries are going to search for one, but not the other?
----
Marc G. Fournier Hub.Org Networking Services (http://www.hub.org)
Email: scrappy@hub.org Yahoo!: yscrappy ICQ: 7615664
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: scrappy@postgresql.org, tgl@sss.pgh.pa.us
Subject: Re: Putting an INDEX on a boolean field?
In-Reply-To: <20050617020039.P90456@ganymede.hub.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox