Dangling operator family after DROP TYPE

From: Yoran Heling <contact(at)yorhel(dot)nl>
To: pgsql-bugs(at)lists(dot)postgresql(dot)org
Subject: Dangling operator family after DROP TYPE
Date: 2024-12-06 15:15:20
Message-ID: Z1MVCOh1hprjK5Sf@gmai021
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Hello list,

pg_upgrade was failing on one of my databases and, while digging a bit,
I found that the database in question contained a dangling operator
family for a type that didn't exist anymore.

I've attached a script to recreate this situation: creating a new type,
defining an operator class for it and then dropping the type causes the
implicitly created operator family to remain.

Attempting to drop this operator family results in an error. Attempting
to do a dump/restore results in a syntax error on restore.

The problematic database I found this on was running 15.10, but with the
attached script I can also reproduce it on 17.2.

Happy to provide more information as needed,

Yoran.

Attachment Content-Type Size
t.sql application/sql 2.8 KB

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2024-12-06 17:15:56 Re: Dangling operator family after DROP TYPE
Previous Message Laurenz Albe 2024-12-06 13:21:01 Re: Install postgres 14 on SLES 15 SP1