From: | Justin Pryzby <pryzby(at)telsasoft(dot)com> |
---|---|
To: | Ajay P S <ajayps547(at)gmail(dot)com> |
Cc: | pgsql-hackers(at)lists(dot)postgresql(dot)org |
Subject: | Re: Regarding Plan tree output(Index/Bitmap Scan) |
Date: | 2023-04-12 01:33:23 |
Message-ID: | ZDYKY7IOESpiT2bW@telsasoft.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Tue, Apr 11, 2023 at 06:09:41PM -0700, Ajay P S wrote:
> I am trying to understand the Plan tree for select queries. Can you
> please help me with the below queries?
>
> 1) Why is there a difference in plan tree for these two queries? User
> table tidx1 has an index on column 'a' .
Based on the query planner's cost estimate of the different scans.
> 2) Why do we do Index scan and not Bitmap Index Scan for catalog tables?
There's no reason why it can't happen in general.
But you queried pg_class on a unique column, returning at most one row.
A bitmap couldn't help by making the I/O more sequential. It can only
add overhead.
You can compare the costs of various plans by running EXPLAIN with
various enable_* GUCs to off.
BTW, your question should be directed to another list - this list is for
bug reports and development.
--
Justin
From | Date | Subject | |
---|---|---|---|
Next Message | Stephen Frost | 2023-04-12 01:45:13 | Re: longfin missing gssapi_ext.h |
Previous Message | Stephen Frost | 2023-04-12 01:30:16 | Re: longfin missing gssapi_ext.h |