public inbox for [email protected]  
help / color / mirror / Atom feed
From: Lukas Eder <[email protected]>
To: jian he <[email protected]>
Cc: Vik Fearing <[email protected]>
Cc: [email protected]
Cc: PG Bug reporting form <[email protected]>
Subject: Re: BUG #19418: SQL/JSON JSON_VALUE() does not conform to ISO/IEC 9075-2:2023(E) 6.34 <JSON value constructor>
Date: Tue, 3 Mar 2026 08:16:49 +0100
Message-ID: <CAB4ELO7eg5O4+Z+Xt653FX9EDkyZzV-JO6ii73q9sK17gg9LpA@mail.gmail.com> (raw)
In-Reply-To: <CACJufxFRtto3WCDLusTsWQZqSdBqc9_LEuA_3S4sjfU_-U7ROw@mail.gmail.com>
References: <[email protected]>
	<[email protected]>
	<CACJufxFRtto3WCDLusTsWQZqSdBqc9_LEuA_3S4sjfU_-U7ROw@mail.gmail.com>

That was a typo. I meant to refer to JSON_ARRAY, not JSON_VALUE in the
subject title. The issue is specifically about <JSON array constructor by
query> (I also made a typo there, sorry for that)

On Tue, Mar 3, 2026 at 3:42 AM jian he <[email protected]> wrote:

> On Thu, Feb 26, 2026 at 10:20 PM Vik Fearing <[email protected]>
> wrote:
> >
> > > Try this:
> > >
> > >    select json_array(select 1 where false);
> > >
> > > It produces NULL, not []
> >
> >
> > I can confirm that postgres violates the standard here.
> >
> > --
>
> Since the subject title mentioned JSON_VALUE.
>
> SELECT JSON_VALUE(((select NULL where false)), '$');
> SELECT JSON_QUERY(((select NULL where false)), '$');
> SELECT JSON_EXISTS(((select NULL where false)), '$');
>
> Should the above produce []?
>
>
>
> --
> jian
> https://www.enterprisedb.com/
>


reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected], [email protected], [email protected], [email protected]
  Subject: Re: BUG #19418: SQL/JSON JSON_VALUE() does not conform to ISO/IEC 9075-2:2023(E) 6.34 <JSON value constructor>
  In-Reply-To: <CAB4ELO7eg5O4+Z+Xt653FX9EDkyZzV-JO6ii73q9sK17gg9LpA@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox