Re: PATCH: jsonpath string methods: lower, upper, initcap, l/r/btrim, replace, split_part
Florents Tselai <florents.tselai@gmail.com>
From: Florents Tselai <florents.tselai@gmail.com>
To: Andrew Dunstan <andrew@dunslane.net>
Cc: "David E. Wheeler" <david@justatheory.com>, pgsql-hackers <pgsql-hackers@lists.postgresql.org>, Chao Li <li.evan.chao@gmail.com>, Álvaro Herrera <alvherre@kurilemu.de>, Tom Lane <tgl@sss.pgh.pa.us>, Peter Eisentraut <peter@eisentraut.org>, Robert Haas <robertmhaas@gmail.com>, Alexander Korotkov <aekorotkov@gmail.com>, jian he <jian.universality@gmail.com>
Date: 2026-04-02T19:57:28Z
Lists: pgsql-hackers
On Thu, Apr 2, 2026 at 10:21 PM Andrew Dunstan <andrew@dunslane.net> wrote: > > On 2026-03-28 Sa 11:58 AM, David E. Wheeler wrote: > > On Mar 28, 2026, at 11:02, Andrew Dunstan <andrew@dunslane.net> <andrew@dunslane.net> wrote: > > > The key_name production is what allows a keyword to also be used as an object key in $.keyname syntax. The trim keywords (ltrim, rtrim, btrim) were added there, so $.ltrim as a key works. But $.lower, > $.upper, $.initcap, $.replace, and $.split_part as keys would all break. > > Ooh, right. It has been so long since I looked at this stuff that I forgot. Thanks for the reminder. > > > There are tests added for it. > > And for this! > > > > > Committed. > Boom! Thanks so much for this.
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Add additional jsonpath string methods
- bd4f879a9cdd 19 (unreleased) landed
-
Rename jsonpath method arg tokens
- a35c9d524ed0 19 (unreleased) landed
-
Fix transient memory leakage in jsonpath evaluation.
- 5a2043bf7131 19 (unreleased) cited
-
Make jsonpath .string() be immutable for datetimes.
- cb599b9ddfcc 18.0 cited