Re: Why a bitmap scan in this case? - Mailing list pgsql-performance

From Greg Sabino Mullane
Subject Re: Why a bitmap scan in this case?
Date
Msg-id CAKAnmmL327t5MRJ2uonQ3JB5bLegRbfa-WtpaTNBnbJ1iVef5Q@mail.gmail.com
Whole thread Raw
In response to Why a bitmap scan in this case?  (Jon Zeppieri <zeppieri@gmail.com>)
Responses Re: Why a bitmap scan in this case?
List pgsql-performance
Why wouldn't it do an index (or, really, an index only) scan in this case

Well, it did do an index scan (and a bitmap scan is a pretty good solution here), but as to why no indexonly scan, there is probably not enough assurance that it won't have to hit the heap heavily anyway. Try doing a SET enable_bitmapscan=0; and re-run with EXPLAIN ANALYZE. If you see a large number of "Heap Fetches", that could be why. Vacuum the table and try again after doing SET enable_bitmapscan=1;

Cheers,
Greg



pgsql-performance by date:

Previous
From: Jon Zeppieri
Date:
Subject: Why a bitmap scan in this case?
Next
From: Jon Zeppieri
Date:
Subject: Re: Why a bitmap scan in this case?