Re: Full Text index is not using during OR operation for multiple table join

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: Full Text index is not using during OR operation for multiple table join
Дата
Msg-id AANLkTi=xjf4J6YJx9oMHQ=7ZZnNRnvE_BVtD+XrojNVc@mail.gmail.com
обсуждение исходный текст
Ответ на Full Text index is not using during OR operation for multiple table join  (AI Rumman <rummandba@gmail.com>)
Список pgsql-bugs
On Mon, Nov 29, 2010 at 5:27 AM, AI Rumman <rummandba@gmail.com> wrote:
> Full Text index is not using during OR operation for multiple table join:

Hmm.  If you have a condition of the form

<some-expression-involving-table-A> OR <some-expression-involving-table-B>

....then the system is going to have to join those tables before
evaluating that condition.  It can't scan A and throw away rows that
don't match the first part of the condition, because they might match
the second prong, and visca versa.

You can sometimes speed these queries up by rewriting them as a UNION
ALL query.  Maybe it'd be nice to make the planner consider such plans
automatically, but that'd be tricky to make work, I think.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

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

Предыдущее
От: Robert Haas
Дата:
Сообщение: Re: BUG #5798: Some weird error with pl/pgsql procedure
Следующее
От: Christopher Head
Дата:
Сообщение: Re: BUG #5559: Full SSL verification fails when hostaddr provided