Re: Oversight in reparameterize_path_by_child leading to executor crash

Поиск
Список
Период
Сортировка
От Richard Guo
Тема Re: Oversight in reparameterize_path_by_child leading to executor crash
Дата
Msg-id CAMbWs48ZfxwRobV-QP1mt_16+2iDbfw_pdsnuzmTJntCPCdD0w@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Oversight in reparameterize_path_by_child leading to executor crash  (Robert Haas <robertmhaas@gmail.com>)
Ответы Re: Oversight in reparameterize_path_by_child leading to executor crash
Список pgsql-hackers

On Tue, Jan 16, 2024 at 2:30 AM Robert Haas <robertmhaas@gmail.com> wrote:
On Mon, Jan 8, 2024 at 3:32 AM Richard Guo <guofenglinux@gmail.com> wrote:
> Thanks for the suggestion.  Attached is an updated patch which is added
> with a commit message that tries to explain the problem and the fix.

This is great. The references to "the sampling infos" are a little bit
confusing to me. I'm not sure if this is referring to
TableSampleClause objects or what.

Yeah, it's referring to TableSampleClause objects.  I've updated the
commit message to clarify that.  In passing I also updated the test
cases a bit.  Please see
v10-0001-Postpone-reparameterization-of-paths-until-when-creating-plans.patch
 
> Fair point.  I think we can back-patch a more minimal fix, as Tom
> proposed in [1], which disallows the reparameterization if the path
> contains sampling info that references the outer rel.  But I think we
> need also to disallow the reparameterization of a path if it contains
> restriction clauses that reference the outer rel, as such paths have
> been found to cause incorrect results, or planning errors as in [2].

Do you want to produce a patch for that, to go along with this patch for master?

Sure, here it is:
v10-0001-Avoid-reparameterizing-Paths-when-it-s-not-suitable.patch

Thanks
Richard
Вложения

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: make pg_ctl more friendly
Следующее
От: Jeevan Chalke
Дата:
Сообщение: Re: More new SQL/JSON item methods