From 203571a0402face9feb92a058d8423317501545e Mon Sep 17 00:00:00 2001 From: Peter Eisentraut Date: Wed, 4 Dec 2019 23:46:00 +0100 Subject: [PATCH] Remove comment about SET STATISTICS on system tables It was once possible to do ALTER TABLE ... SET STATISTICS on system tables without allow_sytem_table_mods. This was changed apparently by accident between PostgreSQL 9.1 and 9.2, but a code comment still claimed this was possible. Remove that comment. (Maybe someone wants to revive that functionality, but not right now.) --- src/backend/commands/tablecmds.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/backend/commands/tablecmds.c b/src/backend/commands/tablecmds.c index 5440eb9015..55b9b63336 100644 --- a/src/backend/commands/tablecmds.c +++ b/src/backend/commands/tablecmds.c @@ -6707,10 +6707,8 @@ static void ATPrepSetStatistics(Relation rel, const char *colName, int16 colNum, Node *newValue, LOCKMODE lockmode) { /* - * We do our own permission checking because (a) we want to allow SET - * STATISTICS on indexes (for expressional index columns), and (b) we want - * to allow SET STATISTICS on system catalogs without requiring - * allowSystemTableMods to be turned on. + * We do our own permission checking because we want to allow SET + * STATISTICS on indexes (for expressional index columns). */ if (rel->rd_rel->relkind != RELKIND_RELATION && rel->rd_rel->relkind != RELKIND_MATVIEW && -- 2.24.0