Skip site navigation (1) Skip section navigation (2)

Re: bug? rules fail to cascade after NOT IN

From: Brandon Craig Rhodes <brandon(at)oit(dot)gatech(dot)edu>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: bug? rules fail to cascade after NOT IN
Date: 2003-03-04 04:01:11
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)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               
Georgia Tech                                            brandon(at)oit(dot)gatech(dot)edu

In response to

pgsql-hackers by date

Next:From: Chris SuttonDate: 2003-03-04 15:03:59
Subject: Best setup for RAM drive
Previous:From: Tom LaneDate: 2003-03-04 03:45:46
Subject: Re: bug? rules fail to cascade after NOT IN

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group