Re: Keep notnullattrs in RelOptInfo (Was part of UniqueKey patch series)

Поиск
Список
Период
Сортировка
От Andy Fan
Тема Re: Keep notnullattrs in RelOptInfo (Was part of UniqueKey patch series)
Дата
Msg-id CAKU4AWpQmMdRhxwRBAL44BTzdJRi7oHj3-phinPTJS8w+qz7ig@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Keep notnullattrs in RelOptInfo (Was part of UniqueKey patch series)  (Andy Fan <zhihui.fan1213@gmail.com>)
Список pgsql-hackers
Unknown why people have so little interest in this, AFAICS, there are more great
usages of UniqueKey rather than the 'marking-distinct-as-noop'. The most
exciting usage for me is it is helpful for JoinRel's pathkey.

Take an example of this:

SELECT .. FROM t1 JOIN t2 ON t1.any_column = t2.uniquekey;
SELECT .. FROM t1 LEFT JOIN t2 ON t1.any_column = t2.uniquekey;

Suppose before the join, t1 has a pathkey X,  t2 has PathKey y. Then
(t1.X, t2.Y) is
ordered as well for JoinRel(t1, t2).  Then the pathkey of JoinRel(t1,
t2)  has a lot
of usage again.  Currently after the joining, only the outer join's
pathkey is maintained.

As for the extra planning cost of this, it looks like our current
infrastructure can support it
well since we know all the information when we generate the pathkey
for the Join Path.

-- 
Best Regards
Andy Fan (https://www.aliyun.com/)



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

Предыдущее
От: Michael Paquier
Дата:
Сообщение: Re: Commitfest 2021-11 Patch Triage - Part 1
Следующее
От: "tanghy.fnst@fujitsu.com"
Дата:
Сообщение: RE: row filtering for logical replication