Re: Why a bitmap scan in this case?

2024-12-20 Thread Jon Zeppieri
On Fri, Dec 20, 2024 at 4:57 AM Frédéric Yhuel wrote: > > > > On 12/20/24 09:16, Frédéric Yhuel wrote: > > > > > > On 12/19/24 20:09, Jon Zeppieri wrote: > >> The table is freshly vacuumed. If I disable bitmap scans, it will do > >> an index only scan, which performs better. For the bitmap heap sc

Re: Why a bitmap scan in this case?

2024-12-20 Thread Frédéric Yhuel
On 12/20/24 09:16, Frédéric Yhuel wrote: On 12/19/24 20:09, Jon Zeppieri wrote: The table is freshly vacuumed. If I disable bitmap scans, it will do an index only scan, which performs better. For the bitmap heap scan, it says "Heap Blocks: exact=27393," whereas for the index only scan, it's

Re: Why a bitmap scan in this case?

2024-12-20 Thread Frédéric Yhuel
On 12/19/24 20:09, Jon Zeppieri wrote: The table is freshly vacuumed. If I disable bitmap scans, it will do an index only scan, which performs better. For the bitmap heap scan, it says "Heap Blocks: exact=27393," whereas for the index only scan, it's "Heap Fetches: 27701." So you have 100% h