Re: [HACKERS] Partitioned tables and relfilenode

Поиск
Список
Период
Сортировка
От Simon Riggs
Тема Re: [HACKERS] Partitioned tables and relfilenode
Дата
Msg-id CANP8+jLM3Gdkr=wysD9JJaX52pXBh_rAyE27AbkfuM34Nm4qMQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: [HACKERS] Partitioned tables and relfilenode  (Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>)
Ответы Re: [HACKERS] Partitioned tables and relfilenode
Список pgsql-hackers
On 16 March 2017 at 10:03, Amit Langote <Langote_Amit_f8@lab.ntt.co.jp> wrote:
> On 2017/03/15 7:09, Robert Haas wrote:

>> I think that eliding the Append node when there's only one child may
>> be unsafe in the case where the child's attribute numbers are
>> different from the parent's attribute numbers.  I remember Tom making
>> some comment about this when I was working on MergeAppend, although I
>> no longer remember the specific details.
>
> Append node elision does not occur in the one-child case.  With the patch:
...
> create table q1 partition of q for values in (1);
> explain select * from q;
>                          QUERY PLAN
> ------------------------------------------------------------
>  Append  (cost=0.00..35.50 rows=2550 width=4)
>    ->  Seq Scan on q1  (cost=0.00..35.50 rows=2550 width=4)
> (2 rows)
>
> Maybe that should be done, but this patch doesn't implement that.

Robert raises the possible problem that removing the Append wouldn't
work when the parent and child attribute numbers don't match. Surely
that never happens with partitions, by definition?

-- 
Simon Riggs                http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services



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

Предыдущее
От: Pavel Stehule
Дата:
Сообщение: Re: [HACKERS] [COMMITTERS] pgsql: Add missing support for new node fields
Следующее
От: Andres Freund
Дата:
Сообщение: Re: [HACKERS] Patch: Write Amplification Reduction Method (WARM)