Re: [HACKERS] trouble with rules - Mailing list pgsql-hackers

From jwieck@debis.com (Jan Wieck)
Subject Re: [HACKERS] trouble with rules
Date
Msg-id m109u8B-000EBRC@orion.SAPserv.Hamburg.dsh.de
Whole thread Raw
In response to Re: [HACKERS] trouble with rules  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: [HACKERS] trouble with rules  (Bruce Momjian <maillist@candle.pha.pa.us>)
List pgsql-hackers
>
> jwieck@debis.com (Jan Wieck) writes:
> >     I've only noticed while browsing through the code why he  did
> >     comment  out  those things. He's comparing memoy addresses of
> >     nodes, what doesn't work any more after copyObject(). If he's
> >     not available right now, we must fix that part.
>
> Is there more to do than using equal() instead of a plain pointer
> compare?
>
> There might be --- for example the collapsing-UNION problem I mentioned
> yesterday is a case where using equal() allows an overly aggressive
> optimization.  Where are these comparisons and what are they for?

    rewriteHandler.c 1691 and 2908... and rewriteManip.c 175, 403
    and 1068.  Now that I've looked closer  I  see  that  it  are
    assignments.  All  of  them  have  to  do  with  sublinks and
    lefttree-aggregate issues. Shouldn't be too  hard  to  figure
    out  what's right and it will give us some additional queries
    for the rule system checks.

    So can someone please tell me how INTERSECT/EXCEPT works?

    I'll deuglify the code while working on  it  then  :-}.  It's
    really  hard  to  read  (must have been written in a 120 char
    wide window or so).


Jan

--

#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me.                                  #
#======================================== jwieck@debis.com (Jan Wieck) #

pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Commercial support, was Re: [HACKERS] v6.4.3 ?
Next
From: Bruce Momjian
Date:
Subject: Re: [HACKERS] trouble with rules