Re: BUG #17694: In JSONPath expressions, characters between leading $ and dot appear to be ignored - Mailing list pgsql-bugs

From David E. Wheeler
Subject Re: BUG #17694: In JSONPath expressions, characters between leading $ and dot appear to be ignored
Date
Msg-id 7B406A27-7142-4F6D-976A-207B4487C7C3@justatheory.com
Whole thread Raw
In response to Re: BUG #17694: In JSONPath expressions, characters between leading $ and dot appear to be ignored  ("David G. Johnston" <david.g.johnston@gmail.com>)
Responses Re: BUG #17694: In JSONPath expressions, characters between leading $ and dot appear to be ignored
List pgsql-bugs
On Nov 24, 2022, at 12:16, David G. Johnston <david.g.johnston@gmail.com> wrote:

> There is a bug in this area though the syntax itself is valid since you've simply defined a variable.

Sorry, I don’t follow. What variable is defined? I mean `$` is a variable for the whole expression, and always required
atthe start of a JSONPath, AFAICT. But when running 

    select '{"foo": 1}' @? ‘$foo'

or

    select '{}' @? ‘$foo'

(both of which incorrectly return true), there is no `$foo` path; it has to be `$.foo`.

Best,

David


Attachment

pgsql-bugs by date:

Previous
From: "David G. Johnston"
Date:
Subject: Re: BUG #17696: Creation of deferrable initially deferred constraint breaks before transaction commit
Next
From: "David G. Johnston"
Date:
Subject: Re: BUG #17694: In JSONPath expressions, characters between leading $ and dot appear to be ignored