On Thu, Oct 17, 2024 at 10:37:46PM +0800, jian he wrote:
>
> - <literal>false</literal>, or <literal>unknown</literal>.
> + <literal>false</literal>, or <literal>NULL</literal>.
>
> nearby are all examples related to jsonb_path_query.
> As mentioned before, jsonb_path_query returns JSON null.
> so change to
> + <literal>false</literal>, or <literal>null</literal>
> would be better.
>
> since we can select 'null'::jsonb;
> but cannot
> select 'NULL'::jsonb;
Oh, okay, but I think we need to say JSON null so we are clear --- patch
attached.
--
Bruce Momjian <[email protected]> https://momjian.us
EDB https://enterprisedb.com
When a patient asks the doctor, "Am I going to die?", he means
"Am I going to die soon?"
diff --git a/doc/src/sgml/func.sgml b/doc/src/sgml/func.sgml
index f8a0d76d12b..18117df5843 100644
--- a/doc/src/sgml/func.sgml
+++ b/doc/src/sgml/func.sgml
@@ -17648,7 +17648,7 @@ SELECT '{
element(s) of the queried JSON value, predicate check expressions
return the single three-valued result of the
predicate: <literal>true</literal>,
- <literal>false</literal>, or <literal>unknown</literal>.
+ <literal>false</literal>, or JSON <literal>null</literal>.
For example, we could write this SQL-standard filter expression:
<screen>
<prompt>=></prompt> <userinput>select jsonb_path_query(:'json', '$.track.segments ?(@[*].HR > 130)');</userinput>