The command tag of "ALTER MATERIALIZED VIEW RENAME COLUMN"

From: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
To: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: The command tag of "ALTER MATERIALIZED VIEW RENAME COLUMN"
Date: 2019-10-31 10:38:35
Message-ID: CAHGQGwGUaC03FFdTFoHsCuDrrNvFvNVQ6xyd40==P25WvuBJjg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

The command tag of ALTER MATERIALIZED VIEW is basically
"ALTER MATERIALIZED VIEW". For example,

=# ALTER MATERIALIZED VIEW test ALTER COLUMN j SET STATISTICS 100;
ALTER MATERIALIZED VIEW
=# ALTER MATERIALIZED VIEW test OWNER TO CURRENT_USER;
ALTER MATERIALIZED VIEW
=# ALTER MATERIALIZED VIEW test RENAME TO hoge;
ALTER MATERIALIZED VIEW

This is ok and looks intuitive to users. But I found that the command tag of
ALTER MATERIALIZED VIEW RENAME COLUMN is "ALTER TABLE", not "ALTER VIEW".

=# ALTER MATERIALIZED VIEW hoge RENAME COLUMN j TO x;
ALTER TABLE

Is this intentional? Or bug?

Regards,

--
Fujii Masao

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Ibrar Ahmed 2019-10-31 10:58:49 Re: Allow CREATE OR REPLACE VIEW to rename the columns
Previous Message Sergei Kornilov 2019-10-31 10:02:36 Re: allow online change primary_conninfo