Subject: [PATCH 3/3] Clarify merror messages

From: Kyotaro Horiguchi <[email-masked]>
Date: Wed, 28 Apr 2021 17:25:36 +0900

---
 src/backend/commands/conversioncmds.c | 2 +-
 src/backend/commands/typecmds.c       | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/backend/commands/conversioncmds.c b/src/backend/commands/conversioncmds.c
index 5fed97a2f9..307afb909d 100644
--- a/src/backend/commands/conversioncmds.c
+++ b/src/backend/commands/conversioncmds.c
@@ -127,7 +127,7 @@ CreateConversionCommand(CreateConversionStmt *stmt)
 	if (DatumGetInt32(funcresult) != 0)
 		ereport(ERROR,
 				(errcode(ERRCODE_INVALID_OBJECT_DEFINITION),
-				 errmsg("encoding conversion function %s returned incorrect result for empty input",
+				 errmsg("encoding conversion function %s must return zero for empty input",
 						NameListToString(func_name))));
 
 	/*
diff --git a/src/backend/commands/typecmds.c b/src/backend/commands/typecmds.c
index 036fa69d17..3dd4323386 100644
--- a/src/backend/commands/typecmds.c
+++ b/src/backend/commands/typecmds.c
@@ -4291,7 +4291,7 @@ AlterType(AlterTypeStmt *stmt)
 		if (!superuser())
 			ereport(ERROR,
 					(errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
-					 errmsg("must be superuser to alter a type")));
+					 errmsg("must be superuser to perform all operations")));
 	}
 	else
 	{
-- 
2.27.0

----Next_Part(Wed_Apr_28_17_36_33_2021_627)----