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

Message improvements

This commit is contained in:
Peter Eisentraut
2015-11-16 21:16:42 -05:00
parent 53264c7b1e
commit 5db837d3f2
26 changed files with 78 additions and 82 deletions

View File

@ -1179,7 +1179,7 @@ jsonb_build_object(PG_FUNCTION_ARGS)
if (nargs % 2 != 0)
ereport(ERROR,
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
errmsg("invalid number or arguments: object must be matched key value pairs")));
errmsg("invalid number of arguments: object must be matched key value pairs")));
memset(&result, 0, sizeof(JsonbInState));
@ -1193,7 +1193,7 @@ jsonb_build_object(PG_FUNCTION_ARGS)
if (PG_ARGISNULL(i))
ereport(ERROR,
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
errmsg("arg %d: key cannot be null", i + 1)));
errmsg("argument %d: key must not be null", i + 1)));
val_type = get_fn_expr_argtype(fcinfo->flinfo, i);
/*
@ -1215,7 +1215,7 @@ jsonb_build_object(PG_FUNCTION_ARGS)
if (val_type == InvalidOid || val_type == UNKNOWNOID)
ereport(ERROR,
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
errmsg("arg %d: could not determine data type", i + 1)));
errmsg("argument %d: could not determine data type", i + 1)));
add_jsonb(arg, false, &result, val_type, true);