mirror of
https://github.com/postgres/postgres.git
synced 2025-06-20 15:22:23 +03:00
Improve reporting of run-time-detected indeterminate-collation errors.
pg_newlocale_from_collation does not have enough context to give an error message that's even a little bit useful, so move the responsibility for complaining up to its callers. Also, reword ERRCODE_INDETERMINATE_COLLATION error messages in a less jargony, more message-style-guide-compliant fashion.
This commit is contained in:
@ -139,7 +139,7 @@ DefineVirtualRelation(const RangeVar *relation, List *tlist, bool replace)
|
||||
if (!OidIsValid(def->collOid))
|
||||
ereport(ERROR,
|
||||
(errcode(ERRCODE_INDETERMINATE_COLLATION),
|
||||
errmsg("no collation was derived for view column \"%s\"",
|
||||
errmsg("could not determine which collation to use for view column \"%s\"",
|
||||
def->colname),
|
||||
errhint("Use the COLLATE clause to set the collation explicitly.")));
|
||||
}
|
||||
|
Reference in New Issue
Block a user