Re: BUG #17439: DROP FUNCTION functionName(); drops associated generated column without using CASCADE

From: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Kevin Humphreys <kmanh999(at)gmail(dot)com>, Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com>, "pgsql-bugs(at)lists(dot)postgresql(dot)org" <pgsql-bugs(at)lists(dot)postgresql(dot)org>
Subject: Re: BUG #17439: DROP FUNCTION functionName(); drops associated generated column without using CASCADE
Date: 2022-03-16 02:28:09
Message-ID: CAKFQuwa10Z27W8dm=-DPokw1_gq9TRqMbggg=_ZwdvNG=CYSRg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On Tuesday, March 15, 2022, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>
>
> > Is there any recommendation you would have for mitigation besides not
> > dropping functions that may be used by generated columns?
>
> I don't see any good user-level workaround :-(.
>
>
Create a dummy view that simply calls the function with null inputs. That
view then will at least enforce the dependency.

David J.

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Peter Geoghegan 2022-03-16 07:24:08 VACUUM can set pages all-frozen without also setting them all-visible
Previous Message Tom Lane 2022-03-16 02:23:43 Re: BUG #17439: DROP FUNCTION functionName(); drops associated generated column without using CASCADE