Re: returning parameters from function

From: Martijn van Oosterhout <kleptog(at)svana(dot)org>
To: Rikard Pavelic <rikard(dot)pavelic(at)zg(dot)htnet(dot)hr>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: returning parameters from function
Date: 2006-12-12 10:55:33
Message-ID: 20061212105533.GC28714@svana.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, Dec 12, 2006 at 10:30:07AM +0100, Rikard Pavelic wrote:
> Hi!
>
> Is there any plan to add implicit declaration of returning parameters
> for functions?
> Something like:
> create function list(in a int) returns setof implicit record as

<snip>

Just "setof record" will do. As for the implicit declaration of
variable names, that's harder. I don't know if you can do that without
making things very ambiguous.

> One other feature that I miss, but no so much is:
> storing the entire function, not just the body
> (because of this pg cant remember exactly how I wrote the
> function, and if there are many parameters inside I get a looong first line)

You should get out what you put in, but it won't remember spacing
outside the function body because the lexer eats that.

I have a file with the function as I want it and edit that. That way I
can have the function exactly how I like it.

Have a nice day,
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> From each according to his ability. To each according to his ability to litigate.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Shoaib Mir 2006-12-12 11:02:02 Re: returning parameters from function
Previous Message Martijn van Oosterhout 2006-12-12 10:50:32 Re: Metadata from NEW and OLD constructs?