Re: Show estimated number of groups for IncrementalSort in EXPLAIN

From: Ilia Evdokimov <ilya(dot)evdokimov(at)tantorlabs(dot)com>
To: David Rowley <dgrowleyml(at)gmail(dot)com>
Cc: PostgreSQL Developers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Show estimated number of groups for IncrementalSort in EXPLAIN
Date: 2026-06-23 09:04:04
Message-ID: 7949fb1f-fc3b-4748-b5b2-c55742bc296b@tantorlabs.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 6/23/26 01:39, David Rowley wrote:
> A couple of things about the patch:
>
> 1. I think the new est_input_groups field should be Cardinality rather
> than double. Various other Path types and Plan nodes call this
> "numGroups". I don't see any reason to deviate from that.
> 2. The header comment for cost_incremental_sort needs to be updated to
> mention that p_input_groups may be passed as non-NULL to provide the
> caller with the estimated number of sort groups.

Fixed in v2-patch.

--
Best regards,
Ilia Evdokimov,
Tantor Labs LLC,
https://tantorlabs.com/

Attachment Content-Type Size
v2-0001-Show-estimated-number-of-groups-for-IncrementalSo.patch text/x-patch 6.5 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Siddharth Kothari 2026-06-23 09:08:20 Re: [PATCH] Add RetrieveInstrumentation hook for CustomScan providers
Previous Message Akshay Joshi 2026-06-23 08:57:54 Re: [PATCH] Add pg_get_table_ddl() to reconstruct CREATE TABLE statements