Re: plpgsql: another new reserved word

From: "Marko Kreen" <markokr(at)gmail(dot)com>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "Pavel Stehule" <pavel(dot)stehule(at)gmail(dot)com>, "Jan Wieck" <JanWieck(at)yahoo(dot)com>, "Postgres Hackers" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: plpgsql: another new reserved word
Date: 2007-11-26 10:25:53
Message-ID: e51f66da0711260225w30fca8f4xfb2fcaa09e56cbb4@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 11/10/07, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> The current plpgsql code seems to be designed to force a qualifier to be
> interpreted as a block label if at all possible, even if there are
> more-closely-nested alternative interpretations; so in the above example
> it would assign to the outer variable bar. This seems a tad bogus
> to me. Can anyone comment on how Oracle handles cases like this?

Some googling brought following link:

http://download-uk.oracle.com/docs/cd/B14117_01/appdev.101/b10807/d_names.htm

I have not parsed it completely, but rule seems simple - inner
scope overrides outer one and no magic on unqualified idents,
if ident is unqualified, it wont be matched to schema, block
or some other qualifier. (well, at least no such magic behaviour
is mentioned.)

--
marko

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Simon Riggs 2007-11-26 10:58:28 Re: Autovacuum and OldestXmin
Previous Message Simon Riggs 2007-11-26 08:10:02 Re: 8.3devel slower than 8.2 under read-only load