public inbox for [email protected]
help / color / mirror / Atom feedFrom: jian he <[email protected]>
To: Amit Langote <[email protected]>
Cc: Alvaro Herrera <[email protected]>
Cc: Andres Freund <[email protected]>
Cc: Erik Rijkers <[email protected]>
Cc: Andrew Dunstan <[email protected]>
Cc: PostgreSQL-development <[email protected]>
Subject: Re: remaining sql/json patches
Date: Mon, 22 Jan 2024 08:00:00 +0800
Message-ID: <CACJufxHo1VVk_0th3AsFxqdMgjaUDz6s0F7+j9rYA3d=URw97A@mail.gmail.com> (raw)
In-Reply-To: <CACJufxFTRw_o-Fey-Km1uavuUAZagXFgQLf8DsMoT_qU4AU8hw@mail.gmail.com>
References: <[email protected]>
<[email protected]>
<CA+HiwqEZP-ybbvTZ_2gKJD2p60hvDkL9-UsoKrzirZkwdV60Ng@mail.gmail.com>
<CACJufxFTRw_o-Fey-Km1uavuUAZagXFgQLf8DsMoT_qU4AU8hw@mail.gmail.com>
based on v35.
Now I only applied from 0001 to 0007.
For {DEFAULT expression ON EMPTY} | {DEFAULT expression ON ERROR}
restrict DEFAULT expression be either Const node or FuncExpr node.
so these 3 SQL/JSON functions can be used in the btree expression index.
I made some big changes on the doc. (see attachment)
list (json_query, json_exists, json_value) as a new <section2> may be
a good idea.
follow these two links, we can see the difference.
only apply v35, 0001 to 0007: https://v35-functions-json-html.vercel.app
apply v35, 0001 to 0007 plus my changes:
https://html-starter-seven-pied.vercel.app
minor issues:
+ Note that if the <replaceable>path_expression</replaceable>
+ is <literal>strict</literal>, an error is generated if it yields no
+ items, provided the specified <literal>ON ERROR</literal> behavior is
+ <literal>ERROR</literal>.
how about something like this:
+ Note that if the <replaceable>path_expression</replaceable>
+ is <literal>strict</literal> and <literal>ON ERROR</literal>
behavior is specified
+ <literal>ERROR</literal>, an error is generated if it yields no
+ items
+ <note>
+ <para>
+ SQL/JSON path expression can currently only accept values of the
+ <type>jsonb</type> type, so it might be necessary to cast the
+ <replaceable>context_item</replaceable> argument of these functions to
+ <type>jsonb</type>.
+ </para>
+ </note>
here should it be "SQL/JSON query functions"?
Attachments:
[application/octet-stream] v35-0001-only-allow-Const-node-or-scalar-returning-fun.no-cfbot (3.3K, ../CACJufxHo1VVk_0th3AsFxqdMgjaUDz6s0F7+j9rYA3d=URw97A@mail.gmail.com/2-v35-0001-only-allow-Const-node-or-scalar-returning-fun.no-cfbot)
download
[application/octet-stream] v35-0001-refactor-json_value-json_query-js.sql_json_new_section (13.1K, ../CACJufxHo1VVk_0th3AsFxqdMgjaUDz6s0F7+j9rYA3d=URw97A@mail.gmail.com/3-v35-0001-refactor-json_value-json_query-js.sql_json_new_section)
download
view thread (27+ messages) latest in thread
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], [email protected]
Subject: Re: remaining sql/json patches
In-Reply-To: <CACJufxHo1VVk_0th3AsFxqdMgjaUDz6s0F7+j9rYA3d=URw97A@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