Re: Define jsonpath functions as stable

From: "Jonathan S(dot) Katz" <jkatz(at)postgresql(dot)org>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Erik Rijkers <er(at)xs4all(dot)nl>, Chapman Flack <chap(at)anastigmatix(dot)net>, pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: Define jsonpath functions as stable
Date: 2019-09-18 01:13:18
Message-ID: f40273d9-f415-468d-24fe-32df76ca2d9d@postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 9/17/19 6:40 PM, Tom Lane wrote:
> "Jonathan S. Katz" <jkatz(at)postgresql(dot)org> writes:
>> v2 attached. Thanks!
>
> I whacked this around some (well, quite a bit actually);

So I see :) Thanks.

> notably,
> I thought we'd better describe things that are in our engine but
> not XQuery, as well as vice-versa.

Yeah, that makes sense. Overall it reads really well. One question I had
in my head (and probably should have asked) was answered around the \w
character class wrt collation.

> After a re-read of the XQuery spec, it seems to me that the character
> entry form that they have and we don't is actually "&#NNNN;" like
> HTML, rather than just "#NN". Can anyone double-check that?

Clicking through the XQuery spec eventual got me to here[1] (which warns
me that its out of date, but that is what its "current" specs linked me
to), which describes being able to use "&#[0-9]+;" and "&#[0-9a-fA-F]+;"
to specify characters (which I recognize as a character escape from
HTML, XML et al.).

So based on that, my answer is "yes."

> Does
> it work outside bracket expressions, or only inside?

Looking at the parse tree (start with the "atom"[2]), I read it as being
able to use that syntax both inside and outside the bracket expressions.

Here is a v4. I added some more paragraphs the bullet point that
explains the different flags to make it feel a bit less dense.

Thanks,

Jonathan

[1] https://www.w3.org/TR/2000/WD-xml-2e-20000814#dt-charref
[2] https://www.w3.org/TR/xmlschema-2/#nt-atom

Attachment Content-Type Size
jsonpath-regex-doc-v4.patch text/plain 8.6 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2019-09-18 01:13:20 Re: refactoring - share str2*int64 functions
Previous Message Michael Paquier 2019-09-18 00:58:15 Re: subscriptionCheck failures on nightjar