| From: | Michael Paquier <michael(at)paquier(dot)xyz> |
|---|---|
| To: | Sami Imseih <samimseih(at)gmail(dot)com> |
| Cc: | Dmitry Dolgov <9erthalion6(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
| Subject: | Re: [[BUG] pg_stat_statements crashes with var and non-var expressions in IN clause |
| Date: | 2026-01-19 08:14:46 |
| Message-ID: | aW3n9ocMo_SH0TQJ@paquier.xyz |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Thu, Jan 15, 2026 at 02:53:20PM -0600, Sami Imseih wrote:
>> As far as I recall it was an
>> intentional design decision, and to adjust newa->list_end in such
>> scenarios we need to solve the original problem of finding an end
>> location of any arbitrary expression,
>
> I'm not sure I follow. How would we adjust newa->list_end?
I may be missing something, of course, but Dmitry's message reads as
follows to me:
"It was a design choice to track the start and end locations because
we needed that for arrays, and resetting the locations if we have Vars
in the list like you are suggesting is OK by me."
I am going to re-read a bit more the area and think about a couple of
patterns to test, but I think that your suggested solution should be
OK to disable the list squashing as you are suggesting in this case:
there is nothing we can really do, and IMO that would still be OK for
most users because squashing has been designed for non-Var lists as
far as I know. This is a rare pattern for long lists in IN arrays, as
well. I'll sleep on it for now.
--
Michael
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Chao Li | 2026-01-19 08:20:06 | Re: docs: clarify ALTER TABLE behavior on partitioned tables |
| Previous Message | Soumya S Murali | 2026-01-19 07:32:56 | Re: 001_password.pl fails with --without-readline |