Re: BUG #19903: ALTER COLUMN TYPE: "unexpected object depending on column" internal error via partition key

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: hackerzheng666(at)gmail(dot)com, pgsql-bugs(at)lists(dot)postgresql(dot)org, Heikki Linnakangas <hlinnaka(at)iki(dot)fi>
Subject: Re: BUG #19903: ALTER COLUMN TYPE: "unexpected object depending on column" internal error via partition key
Date: 2026-11-19 16:55:17
Message-ID: CA+TgmoaFsQ=TWZr1b_zWyU8yHp5zBK9CUs3gCh4ebhXLuvnmZg@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On Mon, Nov 16, 2026 at 6:58 PM Andres Freund <andres(at)anarazel(dot)de> wrote:
> Generally around all of this allowing more IMO is an anti-goal. The amount of
> useless corner-case crap that we allow has cost me way way too much time over
> the last months.
>
> Nobody can tell me that it's useful to have partitioning expressions of this
> kind:
>
> -- Check if the rowtype is used in PARTITION BY expression of another table.
> CREATE TABLE gtest31_1 (a int GENERATED ALWAYS AS (123) VIRTUAL);
> CREATE TABLE gtest31_2 (b text) PARTITION BY RANGE ((('(1)'::gtest31_1).a + length(b)));

I understand your frustration here, but I think that randomly refusing
to change the generated expression in some arbitrary subset of cases
is not the level of engineering we want to be doing. To be clear, I'm
not planning to pursue this right now.

--
Robert Haas
Databricks

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Andrey Rachitskiy 2026-11-19 17:32:32 Re: BUG #19921: auto_explain Reads SQL Function Parameters from an Unpinned Buffer
Previous Message Fujii Masao 2026-11-19 15:59:30 Re: BUG #19594: to_char/jsonpath format cache serves a format tree parsed in the wrong strict-mode