Re: remaining sql/json patches

From: Nikita Malakhov <hukutoc(at)gmail(dot)com>
To: Amit Langote <amitlangote09(at)gmail(dot)com>
Cc: Andres Freund <andres(at)anarazel(dot)de>, Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>, Andrew Dunstan <andrew(at)dunslane(dot)net>, jian he <jian(dot)universality(at)gmail(dot)com>, Erik Rijkers <er(at)xs4all(dot)nl>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: remaining sql/json patches
Date: 2023-10-16 08:20:58
Message-ID: CAN-LCVNNjsruFkAGHeF-9W0yTQKuELKAXsyYs3WDTe_SX+9ppg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi!

With the latest set of patches we encountered failure with the following
query:

postgres(at)postgres=# SELECT JSON_QUERY(jsonpath '"aaa"', '$' RETURNING text);
server closed the connection unexpectedly
This probably means the server terminated abnormally
before or while processing the request.
The connection to the server was lost. Attempting reset: Failed.
The connection to the server was lost. Attempting reset: Failed.
Time: 11.165 ms

A colleague of mine, Anton Melnikov, proposed the following changes which
slightly
alter coercion functions to process this kind of error correctly.

Please check attached patch set.

--
Regards,
Nikita Malakhov
Postgres Professional
The Russian Postgres Company
https://postgrespro.ru/

Attachment Content-Type Size
v23-0003-1-transformJsonExprCommon-fixup.patch application/octet-stream 958 bytes
v23-0003-2-json-query-coercion-override.patch application/octet-stream 17.1 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrei Lepikhov 2023-10-16 08:28:13 Re: Removing unneeded self joins
Previous Message Anton A. Melnikov 2023-10-16 08:04:25 Re: Some performance degradation in REL_16 vs REL_15