Re: BUG #15718: DROP TABLE fails if it's partitioned by a key of adeleted enum - Mailing list pgsql-bugs

From Alvaro Herrera
Subject Re: BUG #15718: DROP TABLE fails if it's partitioned by a key of adeleted enum
Date
Msg-id 20190328170413.GA23764@alvherre.pgsql
Whole thread Raw
In response to BUG #15718: DROP TABLE fails if it's partitioned by a key of a deleted enum  (PG Bug reporting form <noreply@postgresql.org>)
Responses Re: BUG #15718: DROP TABLE fails if it's partitioned by a key of adeleted enum  (Alexandru Pisarenco <pisarenco.a@gmail.com>)
List pgsql-bugs
On 2019-Mar-28, PG Bug reporting form wrote:

> Code to replicate the issue:
> https://pastebin.com/rc8q35Qj

Please paste the code in the email.  We don't like external references.

> This happened to our ETL processes that re-create the staging data on each
> run. Enums are defining partition keys for some tables, that then flow into
> tables in another schema. When the schema containing that enum gets dropped,
> the columns that use it are also dropped.

Sounds like we're forgetting to add a dependency on the datatype of the
partition key.

-- 
Álvaro Herrera                https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services



pgsql-bugs by date:

Previous
From: PG Bug reporting form
Date:
Subject: BUG #15720: `executor could not find named tuplestore ABC` in AFTER DELETE trigger referencing OLD TABLE as ABC
Next
From: Alexandru Pisarenco
Date:
Subject: Re: BUG #15718: DROP TABLE fails if it's partitioned by a key of adeleted enum