Re: BUG #15865: ALTER TABLE statements causing "relation already exists" errors when some indexes exist
Alvaro Herrera <alvherre@2ndquadrant.com>
From: Alvaro Herrera <alvherre@2ndquadrant.com>
To: keith.fiske@crunchydata.com, pgsql-bugs@lists.postgresql.org, Tom Lane <tgl@sss.pgh.pa.us>
Date: 2019-06-20T20:45:05Z
Lists: pgsql-bugs, pgsql-hackers
On 2019-Jun-20, PG Bug reporting form wrote:
> When testing the setup of our monitoring platform, we started running into
> an error when using PostgreSQL as a backend for Grafana. We narrowed down
> the issue to only occurring with the latest point release of PG,
> specifically 11.4, 10.9 and 9.6.14 (previous major versions were not tested
> at this time). The issue can be recreated by following the setup steps for
> Grafana with a PG backend and it will occur when the Grafana service is
> started for the first time and it tries to set up its schema in PG. We do
> not see the error occurring with the previous minor versions (11.3, 10.8,
> 9.6.13).
Confirmed. Bisection says that
commit e76de886157b7f974d4d247908b242607cfbf043
Author: Tom Lane <tgl@sss.pgh.pa.us>
AuthorDate: Wed Jun 12 12:29:24 2019 -0400
CommitDate: Wed Jun 12 12:29:39 2019 -0400
Fix ALTER COLUMN TYPE failure with a partial exclusion constraint.
is the culprit.
--
Álvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
Commits
-
Simplify psql \d's rule for ordering the indexes of a table.
- 4d6603f28dfc 13.0 landed
-
Purely-cosmetic adjustments in tablecmds.c.
- ccfcc8fdbd9b 12.0 landed
-
Further fix ALTER COLUMN TYPE's handling of indexes and index constraints.
- f946a409143d 12.0 landed
- ddfb1b2eeaec 9.4.24 landed
- da1041fc3a2b 9.6.15 landed
- cb8962ce8eb4 10.10 landed
- afaf48afb107 11.5 landed
- 316f68932824 9.5.19 landed
-
Fix ALTER COLUMN TYPE failure with a partial exclusion constraint.
- e76de886157b 12.0 cited