Re: bug? rules fail to cascade after NOT IN

Поиск
Список
Период
Сортировка
От Brandon Craig Rhodes
Тема Re: bug? rules fail to cascade after NOT IN
Дата
Msg-id w6r89n7pbs.fsf@guinness.ts.gatech.edu
обсуждение исходный текст
Ответ на Re: bug? rules fail to cascade after NOT IN  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
Tom Lane <tgl@sss.pgh.pa.us> writes:

> While rule-as-macro works beautifully for views, I've never been
> entirely satisfied with it for updating queries. ... It would take a
> rather fundamental redesign of the rule system to do differently,
> though.  Are you volunteering?

From what I have seen of the planner, its plans look like a funnel -
operator results are repeatedly combined until the result narrows to
exactly the rows specified by the user.  But if NEW and OLD are to
truly become the tuples that were inserted, updated, or deleted, then
plans might being to look like trees that, after combining into a
trunk, start branching out again to form roots - because the resulting
rows will not only be, say, inserted into a table, but might be shared
between several rules that will then have their own operations to
perform upon the result.

And yes, I am volunteering. :-)

-- 
Brandon Craig Rhodes                         http://www.rhodesmill.org/brandon
Georgia Tech                                            brandon@oit.gatech.edu


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: bug? rules fail to cascade after NOT IN
Следующее
От: Rod Taylor
Дата:
Сообщение: Re: [PATCHES] ALTER SEQUENCE