mirror of
https://github.com/postgres/postgres.git
synced 2025-04-25 21:42:33 +03:00
Don't allow ALTER MATERIALIZED VIEW ADD UNIQUE.
Was accidentally allowed, but not documented and lacked support for rename or drop once created. Per report from Noah Misch.
This commit is contained in:
parent
d2fa20acdd
commit
cdcddc4a5a
@ -3031,7 +3031,7 @@ ATPrepCmd(List **wqueue, Relation rel, AlterTableCmd *cmd,
|
|||||||
pass = AT_PASS_DROP;
|
pass = AT_PASS_DROP;
|
||||||
break;
|
break;
|
||||||
case AT_AddIndex: /* ADD INDEX */
|
case AT_AddIndex: /* ADD INDEX */
|
||||||
ATSimplePermissions(rel, ATT_TABLE | ATT_MATVIEW);
|
ATSimplePermissions(rel, ATT_TABLE);
|
||||||
/* This command never recurses */
|
/* This command never recurses */
|
||||||
/* No command-specific prep needed */
|
/* No command-specific prep needed */
|
||||||
pass = AT_PASS_ADD_INDEX;
|
pass = AT_PASS_ADD_INDEX;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user