Skip site navigation (1) Skip section navigation (2)

Re: bit map indexes in postgres

From: Chris Browne <cbbrowne(at)acm(dot)org>
To: pgsql-novice(at)postgresql(dot)org
Subject: Re: bit map indexes in postgres
Date: 2005-10-19 21:56:21
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-novice
bnichols(at)ca(dot)afilias(dot)info (Brad Nicholson) writes:
> Mogin Mohandas wrote:
>>Hi all,
>>           Does anybody have any idea whether there is any Bit-map
>>Index functionality in Postgres. Atleast is there methods to extend
>>postgres with bit-map indexes. Also if anybody has any experience with
>>adding new data types to postgres server, please respond.
> Bitmap indexs are coming in 8.1 (which is currently in beta).

It is worth noticing that these are not bitmaps on disk, but rather
are handled in memory.

Usage would be that you select the matching items from each relevant
b-tree index on disk so that the bitmap is established in memory.

From the release notes:

  Allow index scans to use an intermediate in-memory bitmap (Tom)

     In previous releases, only a single index could be used to do
     lookups on a table. With this feature, if a query has WHERE
     tab.col1 = 4 and tab.col2 = 9, and there is no multicolumn index
     on col1 and col2, but there is an index on col1 and another on
     col2, it is possible to search both indexes and combine the
     results in memory, then do heap fetches for only the rows
     matching both the col1 and col2 restrictions. This is very useful
     in environments that have a lot of unstructured queries where it
     is impossible to create indexes that match all possible access
     conditions. Bitmap scans are useful even with a single index, as
     they reduce the amount of random access needed; a bitmap index
     scan is efficient for retrieving fairly large fractions of the
     complete table, whereas plain index scans are not.
let name="cbbrowne" and tld="" in name ^ "@" ^ tld;;
A VAX is virtually a computer, but not quite.

In response to


pgsql-novice by date

Next:From: Michael GlaesemannDate: 2005-10-19 22:33:30
Subject: Re: SQL return value...
Previous:From: Brad NicholsonDate: 2005-10-19 19:58:32
Subject: Re: bit map indexes in postgres

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group