From: | Richard Guo <guofenglinux(at)gmail(dot)com> |
---|---|
To: | tlhquynh(at)gmail(dot)com, pgsql-bugs(at)lists(dot)postgresql(dot)org |
Subject: | Re: BUG #18589: pg_get_viewdef returns wrong query |
Date: | 2024-08-26 13:07:23 |
Message-ID: | CAMbWs4_nMJ8uXMxd8T7eUh3DbNa9DbNM9_CpuQN5Yk74SUaEEg@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
On Mon, Aug 26, 2024 at 7:22 PM PG Bug reporting form
<noreply(at)postgresql(dot)org> wrote:
> In PostgreSQL 16.3, after I created a view by a statement like
> "create view kvview as select key as value, value as key from kv order by
> value",
> I retrieved a different definition from information_schema.views
> "SELECT key AS value, value AS key FROM kv ORDER BY key".
> I expect ORDER BY column be value.
>
> I tried the same in PostgreSQL 14.12 and 15.7 and got correct equivalent
> definitions.
> "SELECT keyvalue.key AS value, keyvalue.value AS key FROM keyvalue ORDER BY
> keyvalue.key"
>
> So this seems to be a regression.
This is broken starting from 1b4d280ea. The "new" and "old" entries
in a view's rangetable were removed, which results in the varprefix
flag being set to false in this case, as there is now only one rtable
entry.
Thanks
Richard
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2024-08-26 13:58:26 | Re: BUG #18590: during pg14 to pg15 migration , old passwords not migrated to scram-sha from md5 |
Previous Message | PG Bug reporting form | 2024-08-26 08:39:41 | BUG #18590: during pg14 to pg15 migration , old passwords not migrated to scram-sha from md5 |