mirror of
https://github.com/postgres/postgres.git
synced 2025-11-09 06:21:09 +03:00
Assorted translatable string fixes
Mark our rusage reportage string translatable; remove quotes from type names; unify formatting of very similar messages.
This commit is contained in:
@@ -2008,7 +2008,7 @@ json_object_agg_transfn(PG_FUNCTION_ARGS)
|
||||
if (arg_type == InvalidOid)
|
||||
ereport(ERROR,
|
||||
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
|
||||
errmsg("could not determine data type for argument 1")));
|
||||
errmsg("could not determine data type for argument %d", 1)));
|
||||
|
||||
json_categorize_type(arg_type, &state->key_category,
|
||||
&state->key_output_func);
|
||||
@@ -2018,7 +2018,7 @@ json_object_agg_transfn(PG_FUNCTION_ARGS)
|
||||
if (arg_type == InvalidOid)
|
||||
ereport(ERROR,
|
||||
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
|
||||
errmsg("could not determine data type for argument 2")));
|
||||
errmsg("could not determine data type for argument %d", 2)));
|
||||
|
||||
json_categorize_type(arg_type, &state->val_category,
|
||||
&state->val_output_func);
|
||||
|
||||
@@ -1212,7 +1212,7 @@ jsonb_build_object(PG_FUNCTION_ARGS)
|
||||
if (val_type == InvalidOid || val_type == UNKNOWNOID)
|
||||
ereport(ERROR,
|
||||
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
|
||||
errmsg("argument %d: could not determine data type", i + 1)));
|
||||
errmsg("could not determine data type for argument %d", i + 1)));
|
||||
|
||||
add_jsonb(arg, false, &result, val_type, true);
|
||||
|
||||
@@ -1235,7 +1235,7 @@ jsonb_build_object(PG_FUNCTION_ARGS)
|
||||
if (val_type == InvalidOid || val_type == UNKNOWNOID)
|
||||
ereport(ERROR,
|
||||
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
|
||||
errmsg("argument %d: could not determine data type", i + 2)));
|
||||
errmsg("could not determine data type for argument %d", i + 2)));
|
||||
add_jsonb(arg, PG_ARGISNULL(i + 1), &result, val_type, false);
|
||||
}
|
||||
|
||||
@@ -1295,7 +1295,7 @@ jsonb_build_array(PG_FUNCTION_ARGS)
|
||||
if (val_type == InvalidOid || val_type == UNKNOWNOID)
|
||||
ereport(ERROR,
|
||||
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
|
||||
errmsg("argument %d: could not determine data type", i + 1)));
|
||||
errmsg("could not determine data type for argument %d", i + 1)));
|
||||
add_jsonb(arg, PG_ARGISNULL(i), &result, val_type, false);
|
||||
}
|
||||
|
||||
|
||||
@@ -61,7 +61,7 @@ pg_rusage_show(const PGRUsage *ru0)
|
||||
}
|
||||
|
||||
snprintf(result, sizeof(result),
|
||||
"CPU: user: %d.%02d s, system: %d.%02d s, elapsed: %d.%02d s",
|
||||
_("CPU: user: %d.%02d s, system: %d.%02d s, elapsed: %d.%02d s"),
|
||||
(int) (ru1.ru.ru_utime.tv_sec - ru0->ru.ru_utime.tv_sec),
|
||||
(int) (ru1.ru.ru_utime.tv_usec - ru0->ru.ru_utime.tv_usec) / 10000,
|
||||
(int) (ru1.ru.ru_stime.tv_sec - ru0->ru.ru_stime.tv_sec),
|
||||
|
||||
Reference in New Issue
Block a user