Re: Any way to favor index scans, but not bitmap index scans?

From: "Francisco Reyes" <lists(at)stringsutils(dot)com>
To: <pgsql-general(at)postgresql(dot)org>, <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Subject: Re: Any way to favor index scans, but not bitmap index scans?
Date: 2008-07-23 20:44:42
Message-ID: c76fec09f01dcea1bea994d67b67c067@stringsutils.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 4:12 pm 07/23/08 "Francisco Reyes" <lists(at)stringsutils(dot)com> wrote:
> Also, that plan is only 3 seconds.

Minor update.
A co-worker is using another DB.. and re-running my query after he did his
work.. now the query using the index scans takes 2 minutes instead of 3
seconds. 3 seconds was likely data cached.

To re-list the times..
Sequential scan 12 minutes
Bitmap scans 30 minutes
index scan with not bitmap 2 minutes

It is worth pointing out that the bitmap test was run AFTER the sequential
scan test.. right after it.. so it should have benefited from OS caching.
The join_ids table fits completely in memory.

select pg_size_pretty(pg_total_relation_size('join_ids'));
pg_size_pretty
----------------
291 MB
(1 row)

par4mo=# select pg_size_pretty(pg_relation_size('join_ids'));
pg_size_pretty
----------------
94 MB
(1 row)

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2008-07-23 20:47:34 Re: mac install question
Previous Message Oleg Bartunov 2008-07-23 20:28:46 Re: [GENERAL] Fragments in tsearch2 headline