Re: Consider explicit incremental sort for Append and MergeAppend

2025-05-22 Thread Richard Guo
On Mon, May 19, 2025 at 10:21 PM Robert Haas wrote: > On Thu, May 15, 2025 at 9:03 AM Andrei Lepikhov wrote: > > 2. IncrementalSort is not always more effective - it depends on the > > column's number of groups. In my experience, a non-cost-based decision > > one day meets the problematic case, a

Re: Consider explicit incremental sort for Append and MergeAppend

2025-05-19 Thread Robert Haas
On Thu, May 15, 2025 at 9:03 AM Andrei Lepikhov wrote: > 2. IncrementalSort is not always more effective - it depends on the > column's number of groups. In my experience, a non-cost-based decision > one day meets the problematic case, and the people who stick with it are > much more confused than

Re: Consider explicit incremental sort for Append and MergeAppend

2025-05-15 Thread Andrei Lepikhov
On 12/5/2025 11:29, Richard Guo wrote: For ordered Append or MergeAppend, it seems that incremental sort is currently not considered when injecting an explicit sort into subpaths that are not sufficiently ordered. For instance: Thanks for doing this job. I have reviewed your patch and want to p

Consider explicit incremental sort for Append and MergeAppend

2025-05-12 Thread Richard Guo
For ordered Append or MergeAppend, it seems that incremental sort is currently not considered when injecting an explicit sort into subpaths that are not sufficiently ordered. For instance: set enable_seqscan to off; explain (costs off) select hundred as x, two as y from tenk1 union all select th