Re: BitMap Heap Scan & BitMap Index Scan
От
Torsten Förtsch
Тема
Re: BitMap Heap Scan & BitMap Index Scan
Дата
Msg-id
5283486A.7000209@gmx.net
Ответ на
BitMap Heap Scan & BitMap Index Scan (monalee_dba)
Список
Дерево обсуждения
BitMap Heap Scan & BitMap Index Scan monalee_dba <monalee@sungraceinfotech.co.in>
Re: BitMap Heap Scan & BitMap Index Scan Torsten Förtsch <torsten.foertsch@gmx.net>
Re: BitMap Heap Scan & BitMap Index Scan Michael Paquier <michael.paquier@gmail.com>
On 10/11/13 08:32, monalee_dba wrote: > I would like to know, What is BitMap Heap Scan & BitMap Index Scan? When > I use EXPLAIN for query, which has LEFT JOIN with 4 different table then > some time query planner uses Bitmap Heap Scan and some time Bitmap Index > Scan? Check out this great presentation: http://momjian.us/main/writings/pgsql/optimizer.pdf The way I understand it is this (Correct me if I am wrong). The bitmap index scan uses an index to build a bitmap where each bit corresponds to a data buffer (8k). Since a buffer can contain multiple tuples and not all of them must match the condition another run over the heap pages is needed to find the matching tuples. This is the bitmap heap scan. It iterates over the table data buffers found in the bitmap index scan and selects only those tuples that match the filter (hence the recheck thing you see in explain) and visibility conditions. Torsten
В списке pgsql-performance по дате отправления