Re: Indexes on partitioned tables and foreign partitions

Поиск
Список
Период
Сортировка
От Simon Riggs
Тема Re: Indexes on partitioned tables and foreign partitions
Дата
Msg-id CANP8+jJLyg1zMJ9iUXi0_A-CBOYpEztY_QV=DM1xNR6mfM+MOw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Indexes on partitioned tables and foreign partitions  (Arseny Sher <a.sher@postgrespro.ru>)
Ответы Re: Indexes on partitioned tables and foreign partitions
Список pgsql-hackers
On 9 May 2018 at 15:26, Arseny Sher <a.sher@postgrespro.ru> wrote:
>
> Simon Riggs <simon@2ndquadrant.com> writes:
>
>> How much sense is it to have a partitioned table with a mix of local
>> and foreign tables?
>
> Well, as much sense as fdw-based sharding has, for instance. It is
> arguable, but it exists.
>
>> Shouldn't the fix be to allow creation of indexes on foreign tables?
>> (Maybe they would be virtual or foreign indexes??)
>
> Similar ideas were discussed at [1]. There was no wide consensus of even
> what problems such feature would solve. Since currently indexes on
> foreign tables are just forbidden, it seems to me that the best what
> partitioning code can do today is just not creating them.
>
> [1] https://www.postgresql.org/message-id/flat/4F62FD69.2060007%40lab.ntt.co.jp#4F62FD69.2060007@lab.ntt.co.jp

Indexes on foreign tables cause an ERROR, so yes, we already just
don't create them.

You're suggesting silently skipping the ERROR. I can't see a reason for that.

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


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

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: [HACKERS] path toward faster partition pruning
Следующее
От: Robert Haas
Дата:
Сообщение: Re: Global snapshots