Re: Indexes on partitioned tables and foreign partitions

From: Simon Riggs <simon(at)2ndquadrant(dot)com>
To: Arseny Sher <a(dot)sher(at)postgrespro(dot)ru>
Cc: "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Indexes on partitioned tables and foreign partitions
Date: 2018-05-09 13:08:49
Message-ID: CANP8+j+L5W22kuiMMwtjhanqMMos_eRfuE=K6V4Krw_hgpgEcA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 9 May 2018 at 12:50, Arseny Sher <a(dot)sher(at)postgrespro(dot)ru> wrote:
> Hi,
>
> 8b08f7d4 added propagation of indexes on partitioned tables to
> partitions, which is very cool. However, index creation also recurses
> down to foreign tables. I doubt this is intentional, as such indexes are
> forbidden as not making much sense; attempt to create index on
> partitioned table with foreign partition leads to an error
> now. Attached lines fix this.

"Fix"?

How much sense is it to have a partitioned table with a mix of local
and foreign tables?

Shouldn't the fix be to allow creation of indexes on foreign tables?
(Maybe they would be virtual or foreign indexes??)

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

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera 2018-05-09 13:39:07 Re: [HACKERS] path toward faster partition pruning
Previous Message Ashutosh Bapat 2018-05-09 12:52:15 Re: Indexes on partitioned tables and foreign partitions