Re: How to make @id or $id as parameter name in plpgsql, is it available? - Mailing list pgsql-hackers

From Michael Fuhr
Subject Re: How to make @id or $id as parameter name in plpgsql, is it available?
Date
Msg-id 20041124054654.GA36782@winnie.fuhr.org
Whole thread Raw
In response to How to make @id or $id as parameter name in plpgsql, is it available?  ("Arnold.Zhu" <joint@shaucon.com>)
Responses Re: How to make @id or $id as parameter name in plpgsql, is it available?  (Michael Fuhr <mike@fuhr.org>)
List pgsql-hackers
On Thu, Nov 23, 2000 at 11:59:58AM +0800, Arnold.Zhu wrote:

> Can I change postgresql's source to make the following plpgsql works ?
> If could, would you please tell me where can i change the source?
> I want to try it.

No need -- PostgreSQL 8.0 (currently in beta) already supports
argument names in a function's argument list, although I think
only PL/pgSQL currently does anything with them.

> CREATE FUNCTION users_select_by_id(@id int4)

Change @id to be a valid identifier name and it should work.
You can keep using @id if you double-quote it as "@id".

If that's not what you meant then please be more specific.

-- 
Michael Fuhr
http://www.fuhr.org/~mfuhr/


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Big number of schemas (3500) into a single database
Next
From: Michael Fuhr
Date:
Subject: Re: How to make @id or $id as parameter name in plpgsql, is it available?