Oh, sorry for the reply-to-self, but I know I can write an SQL function
with an OUT parameter list to do this. Like creating a custom rowtype
for the job, though, this gets cumbersome if the column-list is long, or
changes to the input tables might ever result in a change to column-list
types, add columns, etc.

Being able to write:

CREATE OR REPLACE FUNCTION blah(IN DATE, OUT a.*, OUT b.*) AS $$
SELECT * FROM a, b;
$$ LANGUAGE 'sql'

... would be somewhat helpful as another form of the ability to expand
rowtypes for use in declarations, but having to list all the OUT
parameters explicitly as I currently do is no better than using CREATE
TYPE to make a custom rowtype or listing all the colums at call-sites
for a RECORD returning function.

-- 
Craig Ringer

Tech-related writing: http://soapyfrogs.blogspot.com/

-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

Reply via email to