On Wed, Dec 24, 2025 at 6:58 PM Robert Haas <robertmhaas@gmail.com> wrote:
>
> Thanks for writing back. I only just noticed this thread again.
>
> On Wed, Dec 17, 2025 at 5:53 AM Ashutosh Bapat
> <ashutosh.bapat.oss@gmail.com> wrote:
> > My patch removed a redundant SET enable_partitionwise_join = on. That
> > change is not included in your commit, I believe, because it's
> > irrelevant to the fix. However, it's better to avoid the redundancy to
> > avoid confusion. PFA patch for the same.
>
> Yeah, I couldn't really understand your test case changes, so I
> basically redid those from scratch. I personally think that the
> regression tests are kind of horrible about how they use SET enable_*
> commands. It's often extremely difficult to figure out what the
> current values are at any given point in what may be a very long test
> case file. I don't have an opinion at the present time on whether
> changing this makes it more or less confusing.
I think there's an unwritten convention that we re/set GUCs nearer the
queries which require/exercise those. That way they are visible. The
test file is about testing partitionwise join, so it's expected that
most of the queries will require PWJ enabled. Seeing
enable_partitionwise_join = true in the middle of the file made me
think that we are disabling PWJ somewhere before to test disabled PWJ
and re-enabling it. But I couldn't find a statement disabling it.
After spending some time and going through the original commit which
added enable_partitionwise_join = true, I realised that it was not
required there. I did that exercise twice, once when writing the patch
and once while comparing my patch and your commit. Removing that
statement will save somebody the same exercise. But I am ok, if we
don't want to remove it.
>
> > [3] https://www.postgresql.org/message-id/786.1565541557%40sss.pgh.pa.us
>
> This is a really interesting link. Your email contained no reference
> to this footnote (unless I missed something) but it seems quite
> relevant to this discussion.
This link was included in one of my very first emails. I included its
reference in some sentence I removed while finalizing the response;
leaving the link behind (no bibtex for emails). Thanks for noticing
it. It is interesting indeed.
--
Best Wishes,
Ashutosh Bapat