Re: pgsql: Only allow returning string types or bytea from json_serialize

From: Michael Paquier <michael(at)paquier(dot)xyz>
To: Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>
Cc: andrew(at)dunslane(dot)net, pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: Re: pgsql: Only allow returning string types or bytea from json_serialize
Date: 2022-07-08 10:20:14
Message-ID: YsgE3g3NNLRCEMcH@paquier.xyz
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

On Fri, Jul 08, 2022 at 03:41:35PM +0900, Kyotaro Horiguchi wrote:
> I noticed that this introcues the following error message.
>
> + errmsg("cannot use RETURNING type %s in JSON_SERIALIZE"
> + format_type_be(returning->typid)),
>
> However, the same file has the following error message.
>
> > errmsg("cannot use RETURNING type %s in %s",
> > format_type_be(returning->typid), fname),
>
> So, couldn't we share the format string to reduce translatable
> messages?

Yeah, I think that you are right, so let's fix this. If Andrew does
not show up, I'll take care of it.
--
Michael

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Robert Haas 2022-07-08 14:40:56 pgsql: Preserve relfilenode of pg_largeobject and its index across pg_u
Previous Message Peter Eisentraut 2022-07-08 09:05:04 pgsql: Adjust node serialization tag of A_Expr for consistency