| From: | David Rowley <dgrowleyml(at)gmail(dot)com> |
|---|---|
| To: | Mark Kirkwood <mark(dot)kirkwood(at)gmail(dot)com> |
| Cc: | pgsql-performance(at)lists(dot)postgresql(dot)org |
| Subject: | Re: Unexpected planner choice in simple JOIN |
| Date: | 2026-01-08 04:14:55 |
| Message-ID: | CAApHDvoGwHEx1cFQyy-p_ExDMbkYZQFxE4h0qt1ubkd=CHrioA@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-performance |
On Thu, 8 Jan 2026 at 17:03, Mark Kirkwood <mark(dot)kirkwood(at)gmail(dot)com> wrote:
>
> I don't think so - while the case I posted used a hash index on the
> child table, exactly the sane behaviour happens if it is a btree (I
> probably should have mentioned that sorry). Background is I discovered
> this while playing about with hash indexes...which I must say - someone
> has done excellent work on as in this *particular cases* they are
> getting me better query performance!
Ok, it seems related to the min_parallel_index_scan_size GUC. If you
zero that, do you get a better plan?
I think the problem is that because the best form of plan for joining
this tiny set of rows to the huge table is a parameterised nested
loop, to parallelise that loop, you need a Parallel node on the outer
side of the Nested Loop. If the index's size is below
min_parallel_index_scan_size then we won't build a partial path for
it.
David
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Mark Kirkwood | 2026-01-08 04:24:02 | Re: Unexpected planner choice in simple JOIN |
| Previous Message | Mark Kirkwood | 2026-01-08 04:03:01 | Re: Unexpected planner choice in simple JOIN |