Re: relhassubclass and partitioned indexes

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: relhassubclass and partitioned indexes
Дата
Msg-id 20181019061759.GE2099@paquier.xyz
обсуждение исходный текст
Ответ на Re: relhassubclass and partitioned indexes  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: relhassubclass and partitioned indexes
Список pgsql-hackers
On Fri, Oct 19, 2018 at 01:45:03AM -0400, Tom Lane wrote:
> Amit Langote <Langote_Amit_f8@lab.ntt.co.jp> writes:
>> Should relhassubclass be set/reset for partitioned indexes?
>
> Seems like a reasonable idea to me, at least the "set" end of it.
> We don't ever clear relhassubclass for tables, so maybe that's
> not necessary for indexes either.

No objections to the proposal.  Allowing find_inheritance_children to
find index trees for partitioned indexes could be actually useful for
extensions like pg_partman.

>> Michael suggested on the linked thread to get rid of relhassubclass
>> altogether, like we did for relhaspkey recently, but I'm not sure whether
>> it would be a good idea right yet.
>
> We got rid of relhaspkey mostly because it was of no use to the backend.
> That's far from true for relhassubclass.

Partitioned tables are expected to have partitions, so the optimizations
related to relhassubclass don't seem much worth worrying.  However
relations not having inherited tables may take a performance hit.  If
this flag removal would be done, we'd need to be careful about the
performance impact and the cost of extra lookups at pg_inherit.
--
Michael

Вложения

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: relhassubclass and partitioned indexes
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: partition tree inspection functions