aboutsummaryrefslogtreecommitdiff
path: root/src/backend/executor/execExprInterp.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/executor/execExprInterp.c')
-rw-r--r--src/backend/executor/execExprInterp.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/backend/executor/execExprInterp.c b/src/backend/executor/execExprInterp.c
index 1633ea83731..c32ac7c5098 100644
--- a/src/backend/executor/execExprInterp.c
+++ b/src/backend/executor/execExprInterp.c
@@ -4634,13 +4634,17 @@ ExecEvalJsonCoercionFinish(ExprState *state, ExprEvalStep *op)
if (DatumGetBool(jsestate->error.value))
ereport(ERROR,
(errcode(ERRCODE_DATATYPE_MISMATCH),
- errmsg("could not coerce ON ERROR expression (%s) to the RETURNING type",
+ /*- translator: first %s is a SQL/JSON clause (e.g. ON ERROR) */
+ errmsg("could not coerce %s expression (%s) to the RETURNING type",
+ "ON ERROR",
GetJsonBehaviorValueString(jsestate->jsexpr->on_error)),
errdetail("%s", jsestate->escontext.error_data->message)));
else if (DatumGetBool(jsestate->empty.value))
ereport(ERROR,
(errcode(ERRCODE_DATATYPE_MISMATCH),
- errmsg("could not coerce ON EMPTY expression (%s) to the RETURNING type",
+ /*- translator: first %s is a SQL/JSON clause (e.g. ON ERROR) */
+ errmsg("could not coerce %s expression (%s) to the RETURNING type",
+ "ON EMPTY",
GetJsonBehaviorValueString(jsestate->jsexpr->on_empty)),
errdetail("%s", jsestate->escontext.error_data->message)));