Re: Jsonpath ** vs lax mode

Поиск
Список
Период
Сортировка
От Alexander Korotkov
Тема Re: Jsonpath ** vs lax mode
Дата
Msg-id CAPpHfdvfW__VPWTvm-15uyBodVnPXFjceQ7+EnwvHz+3PtxCiw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Jsonpath ** vs lax mode  (Alvaro Herrera <alvherre@alvh.no-ip.org>)
Ответы Re: Jsonpath ** vs lax mode  (Alexander Korotkov <aekorotkov@gmail.com>)
Список pgsql-hackers
On Thu, Jan 21, 2021 at 4:35 PM Alvaro Herrera <alvherre@alvh.no-ip.org> wrote:
> On 2021-Jan-21, Alexander Korotkov wrote:
>
> > Requiring strict mode for ** is a solution, but probably too restrictive...
> >
> > What do you think about making just subsequent accessor after ** not
> > to unwrap arrays.  That would be a bit tricky to implement, but
> > probably that would better satisfy the user needs.
>
> Hmm, why is it too restrictive?  If the user needs to further drill into
> the JSON, can't they chain json_path_query calls, specifying (or
> defaulting to) lax mode for the part doesn't include the ** expression?

For sure, there are some walkarounds.  But I don't think all the
lax-mode queries involving ** are affected.  So, it might happen that
we force users to use strict-mode or chain call even if it's not
necessary.  I'm tending to just fix the doc and wait if there are mode
complaints :)

------
Regards,
Alexander Korotkov



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

Предыдущее
От: Alexander Korotkov
Дата:
Сообщение: Re: Jsonpath ** vs lax mode
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: mkid reference