aboutsummaryrefslogtreecommitdiff
path: root/src/backend/parser
diff options
context:
space:
mode:
authorMichael Paquier <michael@paquier.xyz>2021-09-29 15:29:45 +0900
committerMichael Paquier <michael@paquier.xyz>2021-09-29 15:29:45 +0900
commit2cf9cf5d7b5e66202389618a4c08945da352b35c (patch)
tree3e7f6d201f5caaaa736fd983bc5fcf9713a2562a /src/backend/parser
parent2a27dbaeb9088718baa25bc97f2e049e063412db (diff)
downloadpostgresql-2cf9cf5d7b5e66202389618a4c08945da352b35c.tar.gz
postgresql-2cf9cf5d7b5e66202389618a4c08945da352b35c.zip
Clarify use of "statistics objects" in the code
The code inconsistently used "statistic object" or "statistics" where the correct term, as discussed, is actually "statistics object". This improves the state of the code to be more consistent. While on it, fix an incorrect error message introduced in a4d75c8. This error should never happen, as the code states, but it would be misleading. Author: Justin Pryzby Reviewed-by: Álvaro Herrera, Michael Paquier Discussion: https://postgr.es/m/20210924215827.GS831@telsasoft.com Backpatch-through: 14
Diffstat (limited to 'src/backend/parser')
-rw-r--r--src/backend/parser/parse_utilcmd.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/backend/parser/parse_utilcmd.c b/src/backend/parser/parse_utilcmd.c
index 47e315a6cf5..c1d5a5d540b 100644
--- a/src/backend/parser/parse_utilcmd.c
+++ b/src/backend/parser/parse_utilcmd.c
@@ -2893,7 +2893,7 @@ transformIndexStmt(Oid relid, IndexStmt *stmt, const char *queryString)
/*
* transformStatsStmt - parse analysis for CREATE STATISTICS
*
- * To avoid race conditions, it's important that this function rely only on
+ * To avoid race conditions, it's important that this function relies only on
* the passed-in relid (and not on stmt->relation) to determine the target
* relation.
*/
@@ -2949,7 +2949,7 @@ transformStatsStmt(Oid relid, CreateStatsStmt *stmt, const char *queryString)
if (list_length(pstate->p_rtable) != 1)
ereport(ERROR,
(errcode(ERRCODE_INVALID_COLUMN_REFERENCE),
- errmsg("statistics expressions can refer only to the table being indexed")));
+ errmsg("statistics expressions can refer only to the table being referenced")));
free_parsestate(pstate);
@@ -3616,7 +3616,7 @@ transformAlterTableStmt(Oid relid, AlterTableStmt *stmt,
newcmds = lappend(newcmds, newcmd);
}
- /* Append extended statistic objects */
+ /* Append extended statistics objects */
transformExtendedStatistics(&cxt);
/* Close rel */