On 06/22/2011 11:42 PM, Greg Smith wrote:
On 06/22/2011 05:27 PM, Marcus Engene wrote:
I have some tables with bitmask integers. Set bits are the interesting
ones. Usually they are sparse.
If it's sparse, create a partial index that just includes rows where the
bit is set:
http://www.postgresql.org/docs/current/static/indexes-partial.html
That would mean that if different bits are queried there would need to
be several of those indexes.
Maybe it's an alternative to index all rows where misc_bits <> 0 and
include that criterion in the query.
Kind regards
robert
--
Sent via pgsql-performance mailing list (pgsql-performance@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-performance