Using vars in jsonbpath operator ?

Поиск
Список
Период
Сортировка
Искать
От
Markur Sens
Тема
Using vars in jsonbpath operator ?
Дата
Msg-id
4A219290-0DC1-4782-85F6-55CA334192C3@gmail.com
Список
Дерево обсуждения
Using vars in jsonbpath operator ? Markur Sens <markursens@gmail.com>
Re: Using vars in jsonbpath operator ? Thomas Kellerer <shammat@gmx.net>
I understand that on a where clause a gin index can be used for the following predicate

a.data @? '$.results.docs[*].accs[*] ? (@.id == “123")

I have a join query however on the following condition

jsonb_path_exists(a.data, '$.results.docs[*].accs[*] ? (@.number == $id)', jsonb_build_object(‘id', b.id))  but this cannot use a gin index afaik and results in a seq scan.

Is there anyway to use the operator syntax above by passing the b.id variable somwehow so that the gin index can be used ? ? 




В списке pgsql-general по дате отправления
От: Brainmue
Дата:
От: Laurenz Albe
Дата:
FAQ