Re: More jsonpath methods: translate, split, join

From: Florents Tselai <florents(dot)tselai(at)gmail(dot)com>
To: Zsolt Parragi <zsolt(dot)parragi(at)percona(dot)com>
Cc: pgsql-hackers(at)lists(dot)postgresql(dot)org, Corey Huinker <corey(dot)huinker(at)gmail(dot)com>
Subject: Re: More jsonpath methods: translate, split, join
Date: 2026-07-04 08:59:09
Message-ID: CA+v5N41c+9G7iRZ1sev6ZNbNLdNCtkB0uvYw9baS6WBNEfcigg@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sat, Jun 27, 2026 at 8:40 AM Florents Tselai <florents(dot)tselai(at)gmail(dot)com>
wrote:

>
>
> On Fri, Jun 26, 2026 at 11:19 PM Zsolt Parragi <zsolt(dot)parragi(at)percona(dot)com>
> wrote:
>
>> + binary_jbv.type = jbvBinary;
>> + binary_jbv.val.binary.data =
>> &jb_result->root;
>> + binary_jbv.val.binary.len =
>> VARSIZE(jb_result);
>>
>> Shouldn't that use VARSIZE_ANY_EXHDR or VARSIZE(jb_result) - VARHDRSZ?
>>
>
> I think you're right; let's see if Corey comes back with anything else
> before I send out a new version.
>

Here's a v5 that fixes the VARSIZE_ANY_EXHDR Zsolt mentioned above
I've also rearranged the test cases in jsonpath.sql and jsonb_jsonpath.sql
Also added parser error test cases that were missing for translate() in
jsonpath.sql

Attachment Content-Type Size
v5-0001-Add-more-jsonpath-string-methods-.split-.join-.tr.patch application/octet-stream 38.7 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Henson Choi 2026-07-04 08:59:34 Re: Row pattern recognition
Previous Message Bertrand Drouvot 2026-07-04 08:19:46 Re: Re-read subscription state after lock in AlterSubscription