Re: Clause accidentally pushed down ( Possible bug in Making Vars outer-join aware)

Поиск
Список
Период
Сортировка
От Richard Guo
Тема Re: Clause accidentally pushed down ( Possible bug in Making Vars outer-join aware)
Дата
Msg-id CAMbWs48FHw_tTXSbA-_MPaeu7S7JCt6Xs-gxwkx=pvLiwC6eTg@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Clause accidentally pushed down ( Possible bug in Making Vars outer-join aware)  (Andrey Lepikhov <a.lepikhov@postgrespro.ru>)
Ответы Re: Clause accidentally pushed down ( Possible bug in Making Vars outer-join aware)  (Andrey Lepikhov <a.lepikhov@postgrespro.ru>)
Список pgsql-bugs

On Mon, Feb 27, 2023 at 2:23 PM Andrey Lepikhov <a.lepikhov@postgrespro.ru> wrote:
Doing a comparison of pg15 and master initsplan.c I found that a clear
and documented algorithm for delaying the application of a qual is lost
or replaced with some commute_* fields.
It is not clear how we guarantee correct application delay of a qual.
Which part of the code implements it now?
 
Do you mean function check_outerjoin_delay()?  Yes it has been removed
in b448f1c8, since now we consider that outer joins listed in
varnullingrels or phnullingrels are used in the clause, so that the
clause would not be placed below outer joins that should null some of
its vars.

Such as in query

    select * from t1 left join t2 on true where coalesce(t2.a,1) = 1;

we'd consider that the clause uses t2 as well as t1/t2 join, so it
cannot be pushed down below the left join.

Thanks
Richard

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

Предыдущее
От: Richard Guo
Дата:
Сообщение: Re: Clause accidentally pushed down ( Possible bug in Making Vars outer-join aware)
Следующее
От: Andrey Lepikhov
Дата:
Сообщение: Re: Clause accidentally pushed down ( Possible bug in Making Vars outer-join aware)