Re: Calling PL functions with named parameters - Mailing list pgsql-hackers

From Peter Eisentraut
Subject Re: Calling PL functions with named parameters
Date
Msg-id 200408141337.04184.peter_e@gmx.net
Whole thread Raw
In response to Calling PL functions with named parameters  (David Fetter <david@fetter.org>)
List pgsql-hackers
David Fetter wrote:
> I'd like to be able to create functions with named parameters that
> could be called with the names in any order.  For example,
>
> CREATE OR REPLACE FUNCTION foo_func(name TEXT, val INTEGER) AS ...
>
> SELECT foo_func(val AS 23, name AS 'Name goes here');

When that was brought up last time, I think the hard part was what 
syntax to use.  You can't use AS because SQL uses that for something 
different.  => might be OK, but then we'd need to disallow that as 
operator name.

-- 
Peter Eisentraut
http://developer.postgresql.org/~petere/



pgsql-hackers by date:

Previous
From: Christopher Kings-Lynne
Date:
Subject: 7.4 backpatches
Next
From: Oliver Jowett
Date:
Subject: Re: Calling PL functions with named parameters