Re: BUG #19418: SQL/JSON JSON_VALUE() does not conform to ISO/IEC 9075-2:2023(E) 6.34 - Mailing list pgsql-bugs

From Richard Guo
Subject Re: BUG #19418: SQL/JSON JSON_VALUE() does not conform to ISO/IEC 9075-2:2023(E) 6.34
Date
Msg-id CAMbWs49tDE_niKLr4mzsa2BkX7fkWrorBzWheKTBziZ7z9-AuQ@mail.gmail.com
Whole thread
In response to Re: BUG #19418: SQL/JSON JSON_VALUE() does not conform to ISO/IEC 9075-2:2023(E) 6.34  (Amit Langote <amitlangote09@gmail.com>)
Responses Re: BUG #19418: SQL/JSON JSON_VALUE() does not conform to ISO/IEC 9075-2:2023(E) 6.34
Re: BUG #19418: SQL/JSON JSON_VALUE() does not conform to ISO/IEC 9075-2:2023(E) 6.34
List pgsql-bugs
On Mon, Apr 20, 2026 at 6:05 PM Amit Langote <amitlangote09@gmail.com> wrote:
> Agreed that v4 is the better direction.

Thanks for review!

> The comment on orig_query could say "not walked" a bit more helpfully, e.g.
>
> Node       *orig_query;     /* for deparse only; not walked (func is) */

Sounds good.

> I also noticed that the comment for 'func' is incomplete as it is and
> this change warrants an update. Maybe a bit long, but how about:
>
>     Expr       *func;           /* expression producing the result:
>                                  * Aggref/WindowFunc for *AGG,
>                                  * CoalesceExpr for ARRAY_QUERY,
>                                  * json[b]_xxx() call for remaining types */

It seems that func is NULL for "remaining types".  How about we go
with:

  Expr       *func;           /* executable expression:
                               * Aggref/WindowFunc for *AGG,
                               * CoalesceExpr for ARRAY_QUERY,
                               * NULL for other types (executor calls
                               * underlying json[b]_xxx() functions) */

(maybe we should place the multi-line comment above the field.)

- Richard



pgsql-bugs by date:

Previous
From: Richard Guo
Date:
Subject: Re: BUG #19460: FULL JOIN rewriting issue on empty queries
Next
From: Richard Guo
Date:
Subject: Re: BUG #19418: SQL/JSON JSON_VALUE() does not conform to ISO/IEC 9075-2:2023(E) 6.34