Re: BUG #11207: empty path will segfault jsonb #>

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: BUG #11207: empty path will segfault jsonb #>
Дата
Msg-id 22294.1408487132@sss.pgh.pa.us
обсуждение исходный текст
Ответ на BUG #11207: empty path will segfault jsonb #>  (justin.vanwinkle@gmail.com)
Ответы Re: BUG #11207: empty path will segfault jsonb #>  (David G Johnston <david.g.johnston@gmail.com>)
Re: BUG #11207: empty path will segfault jsonb #>  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-bugs
justin.vanwinkle@gmail.com writes:
> select '{"a": {"b":{"c": "foo"}}}'::jsonb #> '{}';
> [ dumps core ]

Hm.  It's not immediately obvious to me what this should be defined to do;
should it throw an error, or return the complete LHS object, or perhaps
return a NULL?  But the author of get_jsonb_path_all() evidently didn't
consider the case.

Easy enough to fix once we settle on a definition.

            regards, tom lane

В списке pgsql-bugs по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: BUG #11211: regexp_matches acts like a WHERE
Следующее
От: David G Johnston
Дата:
Сообщение: Re: BUG #11207: empty path will segfault jsonb #>