1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-30 11:03:19 +03:00

Upgrade internal error message to external

As part of REINDEX CONCURRENTLY, this formerly internal-only error
message becomes potentially user-visible (see regression tests), so
change from errmsg_internal() to errmsg(), and update comment.
This commit is contained in:
Peter Eisentraut
2019-06-24 10:39:12 +02:00
parent 9a81c9fa3f
commit 12e037e209

View File

@ -773,13 +773,13 @@ index_create(Relation heapRelation,
errmsg("concurrent index creation on system catalog tables is not supported"))); errmsg("concurrent index creation on system catalog tables is not supported")));
/* /*
* This case is currently not supported, but there's no way to ask for it * This case is currently not supported. There's no way to ask for it in
* in the grammar anyway, so it can't happen. * the grammar with CREATE INDEX, but it can happen with REINDEX.
*/ */
if (concurrent && is_exclusion) if (concurrent && is_exclusion)
ereport(ERROR, ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED), (errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
errmsg_internal("concurrent index creation for exclusion constraints is not supported"))); errmsg("concurrent index creation for exclusion constraints is not supported")));
/* /*
* We cannot allow indexing a shared relation after initdb (because * We cannot allow indexing a shared relation after initdb (because