From: Andrew Gierth <andrew@tao11.riddles.org.uk>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Michael Paquier <michael@paquier.xyz>
Cc: cyg0810@gmail.com
Cc: pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #17088: FailedAssertion in prepagg.c
Date: Wed, 07 Jul 2021 22:32:56 +0100
Message-ID: <875yxlrf5x.fsf@news-spur.riddles.org.uk> (raw)
In-Reply-To: <1909846.1625692937@sss.pgh.pa.us>
References: <17088-e33882b387de7f5c@postgresql.org>
<YOWJQTovI//DNe8/@paquier.xyz>
<1908212.1625690962@sss.pgh.pa.us>
<87a6mxrggq.fsf@news-spur.riddles.org.uk>
<1909846.1625692937@sss.pgh.pa.us>
>>>>> "Tom" == Tom Lane <tgl@sss.pgh.pa.us> writes:
> Andrew Gierth <andrew@tao11.riddles.org.uk> writes:
>> A number of places in the planner have to explicitly avoid recursing
>> into GroupingFunc->args when walking trees specifically because they
>> are not evaluated. It looks to me like some places where that should
>> have been checked for were missed. Looking into it.
Tom> Hmm. Maybe it'd be better if the default behavior in
Tom> expression_tree_walker/mutator did not include recursing into the
Tom> args, then?
You'd think, but as I recall (I will re-check this to confirm) there
were more places where we _did_ need to recurse (especially during parse
analysis before we've matched up the sortgrouprefs), while most of the
places where recursion needed to be explicitly avoided already needed
special-case handling, so having the default the other way would likely
have required a special-case almost everywhere.
--
Andrew.
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-bugs@postgresql.org
Cc: andrew@tao11.riddles.org.uk, tgl@sss.pgh.pa.us, michael@paquier.xyz, cyg0810@gmail.com, pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #17088: FailedAssertion in prepagg.c
In-Reply-To: <875yxlrf5x.fsf@news-spur.riddles.org.uk>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox