Re: variables in procedures
- From: Stephan Szabo <sszabo(at)megazone23(dot)bigpanda(dot)com>
- To: Martín Marqués <martin(at)bugs(dot)unl(dot)edu(dot)ar>
- Cc: <pgsql-sql(at)postgresql(dot)org>
- Subject: Re: variables in procedures
- Date: Fri, 30 Nov 2001 09:34:47 -0800 (PST)
- Message-id: <20011130093356.A55762-100000@megazone23.bigpanda.com> <text/plain>
On Fri, 30 Nov 2001, [iso-8859-1] Martín Marqués wrote:
> How can I distinguish between the name and the value of a variable?
>
> Example:
>
> CREATE FUNCTION test(VARCHAR) RETURNS INTEGER AS '
>
> DECLARE
> col1 ALIAS FOR $1
> BEGIN
> select col1 from tab where col1=´´col1´´;
> END;
> ´ LANGUAGE 'plpgsql';
>
>
> Is my doubt understood?
AFAIK you don't distinguish, you'll probably need to name
the variable something else.
Home |
Main Index |
Thread Index