aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2017-09-26 15:25:57 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2017-09-26 15:25:57 -0400
commit14f94ac697cf6b70d939a1263d79d32a3362760b (patch)
treed69e6b379bd689c477c27e5f7431ff32a7b58770
parente5c058e2eed865114886823d010cece747914f8d (diff)
downloadpostgresql-14f94ac697cf6b70d939a1263d79d32a3362760b.tar.gz
postgresql-14f94ac697cf6b70d939a1263d79d32a3362760b.zip
Improve wording of error message added in commit 714805010.
Per suggestions from Peter Eisentraut and David Johnston. Back-patch, like the previous commit. Discussion: https://postgr.es/m/E1dv9jI-0006oT-Fn@gemulon.postgresql.org
-rw-r--r--src/backend/commands/analyze.c2
-rw-r--r--src/test/regress/expected/vacuum.out4
2 files changed, 3 insertions, 3 deletions
diff --git a/src/backend/commands/analyze.c b/src/backend/commands/analyze.c
index 4dad36820d0..995b3e1664b 100644
--- a/src/backend/commands/analyze.c
+++ b/src/backend/commands/analyze.c
@@ -396,7 +396,7 @@ do_analyze_rel(Relation onerel, VacuumStmt *vacstmt,
if (bms_is_member(i, unique_cols))
ereport(ERROR,
(errcode(ERRCODE_DUPLICATE_COLUMN),
- errmsg("column \"%s\" of relation \"%s\" is specified twice",
+ errmsg("column \"%s\" of relation \"%s\" appears more than once",
col, RelationGetRelationName(onerel))));
unique_cols = bms_add_member(unique_cols, i);
diff --git a/src/test/regress/expected/vacuum.out b/src/test/regress/expected/vacuum.out
index bf5034ad685..fda1b390c09 100644
--- a/src/test/regress/expected/vacuum.out
+++ b/src/test/regress/expected/vacuum.out
@@ -81,8 +81,8 @@ SQL function "wrap_do_analyze" statement 1
VACUUM FULL vactst;
-- check behavior with duplicate column mentions
VACUUM ANALYZE vaccluster(i,i);
-ERROR: column "i" of relation "vaccluster" is specified twice
+ERROR: column "i" of relation "vaccluster" appears more than once
ANALYZE vaccluster(i,i);
-ERROR: column "i" of relation "vaccluster" is specified twice
+ERROR: column "i" of relation "vaccluster" appears more than once
DROP TABLE vaccluster;
DROP TABLE vactst;