Re: composite types - Mailing list pgsql-general

From Steve Manes
Subject Re: composite types
Date
Msg-id 4085541A.3010004@magpie.com
Whole thread Raw
In response to composite types  (Ivan Sergio Borgonovo <mail@webthatworks.it>)
List pgsql-general
Ivan Sergio Borgonovo wrote:

> I've found this
> http://archives.postgresql.org/pgsql-general/2001-03/msg01459.php
> but I'd like to avoid to declare a table just for a temp.
>
> pseudocode follow
>
> declare struct pippo(
>     integer a;
>     varchar(8) b;
> )
>
> create or replace function functiontest( ) returns pippo
> as '
> declare
>     integer tempa;
>     varchar(8) tempb;
>

I think you might want to look at SRFs (Set Returning Functions).  Here
are a couple of links:

http://techdocs.postgresql.org/guides/SetReturningFunctions
http://www.varlena.com/varlena/GeneralBits/26.html




pgsql-general by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: wishlist: dynamic log volume control
Next
From: Jan Wieck
Date:
Subject: Slony-I heading for release