Re: Fix for tablename in targetlist

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Peter Eisentraut <peter_e(at)gmx(dot)net>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Fix for tablename in targetlist
Date: 2001-05-20 00:38:25
Message-ID: 200105200038.f4K0cPP22929@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> writes:
> > OK, here is another patch that does this:
>
> That seems considerably uglier than your first patch. In particular,
> why aren't you looking for isRel being set in the Ident node? It
> looks to me like you may have changed the behavior in the case where
> the Ident could be either a table or column name.

OK, here is a new patch. I thought I had to go through
transformTargetEntry() -> transformExpr() -> transformIdent() to get
Ident.isRel set. Seems it is set earlier too, so the new code is
shorter. I am still researching the purpose of Ident.isRel. If someone
knows, please chime in. I know it says the Ident is a relation, but why
have a field when you can look it up in the rangetable?

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026

Attachment Content-Type Size
unknown_filename text/plain 2.2 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2001-05-20 00:44:09 Re: Functions returning sets
Previous Message Tom Lane 2001-05-20 00:34:22 Re: C++ Headers