Multiple return 'columns' from postgre pl/pgsql - Mailing list pgsql-novice

From Steve Tucknott
Subject Multiple return 'columns' from postgre pl/pgsql
Date
Msg-id 1091991658.2257.9.camel@retsol1
Whole thread Raw
Responses Re: Multiple return 'columns' from postgre pl/pgsql
List pgsql-novice
Is there a way of doing:
RETURNS INTEGER, CHAR(5), VARCHAR(200),.....
IE return multiple values from a PL/PGSQL function?

(From what I can see so far, you only have 1 return field - although that can be a rowtype or record)

I am converting Informix functions, and returning multiple columns was allowed -  I need to be able to do the same/similar in PostGre. What's the best way?

(Typically the functions return an error code, error text (that are not table based - ie are built in the function and not selected from a table) and two or three columns from a table).



Regards,

Steve Tucknott

ReTSol Ltd

DDI: 01903 828769

pgsql-novice by date:

Previous
From: Michael Glaesemann
Date:
Subject: Re: Design question regarding arrays
Next
From: Tom Lane
Date:
Subject: Re: Multiple return 'columns' from postgre pl/pgsql