Re: UNION ALL with WHERE clause does not use Merge Append

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: UNION ALL with WHERE clause does not use Merge Append
Дата
Msg-id 12520.1345129152@sss.pgh.pa.us
обсуждение исходный текст
Ответ на UNION ALL with WHERE clause does not use Merge Append  (Marti Raudsepp <marti@juffo.org>)
Список pgsql-hackers
Marti Raudsepp <marti@juffo.org> writes:
> Is this just a planner shortcoming or a bug? Or is there some
> justification for this behavior?

Per the comment in is_safe_append_member():
    * It's only safe to pull up the child if its jointree contains exactly    * one RTE, else the AppendRelInfo data
structurebreaks. The one base RTE    * could be buried in several levels of FromExpr, however.    *    * Also, the
childcan't have any WHERE quals because there's no place to    * put them in an appendrel.  (This is a bit
annoying...)

This will probably get fixed someday, but I wouldn't recommend holding
your breath for it.
        regards, tom lane



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

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: cataloguing NOT NULL constraints
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: [COMMITTERS] pgsql: Clean up the #include mess a little.