Re: plpgsql and qualified variable names

From: "Affan Salman" <affan(at)enterprisedb(dot)com>
To: "Heikki Linnakangas" <heikki(at)enterprisedb(dot)com>, "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: <pgsql-hackers(at)postgreSQL(dot)org>
Subject: Re: plpgsql and qualified variable names
Date: 2007-07-14 23:13:41
Message-ID: 469958A5.8010703@enterprisedb.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


> ISTM supporting "somefunc.ambiguous" just gives us another way to
> reference the parameter, and there still isn't any way to refer the
> column.

Could we not, at least, support explicit column disambiguation?

e.g. This PL/SQL procedure:

CREATE OR REPLACE PROCEDURE insert_emp (empno emp.empno%TYPE,
ename emp.ename%TYPE) IS
BEGIN
INSERT INTO emp (empno, ename) VALUES (empno, ename);
END;

is tantamount to writing this:

CREATE OR REPLACE PROCEDURE insert_emp (empno emp.empno%TYPE,
ename emp.ename%TYPE) IS
BEGIN
INSERT INTO emp (emp.empno, emp.ename)
VALUES (insert_emp.empno, insert_emp.ename);
END;

Both are valid, and notice how the latter evinces disambiguation
supported both ways.

--
Affan Salman
EnterpriseDB Corporation http://www.enterprisedb.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2007-07-14 23:52:37 Re: plpgsql and qualified variable names
Previous Message Tom Lane 2007-07-14 23:10:34 Re: plpgsql and qualified variable names