Skip site navigation (1) Skip section navigation (2)

Re: Improving ALTER TYPE support

From: Josh Berkus <josh(at)agliodbs(dot)com>
To: pgsql-hackers(at)postgresql(dot)org
Cc: "John Jawed" <johnjawed(at)gmail(dot)com>
Subject: Re: Improving ALTER TYPE support
Date: 2006-05-24 01:20:26
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers

> I've been working on a function which returns a setof a composite type.
> Everytime I've changed the structure of the returning setof, I've had to
> change the type accordingly, which current means doing a drop type ...
> cascade down to the function. We should allow one of the following:

Why not go all the way and work out a way to define an SRF return type as a 
part of the function?  e.g.

CREATE OR REPLACE FUNCTION some_srf ( param1 int, param2 text )
RETURNS some_srf ( col1 int, col2 numeric ) AS ....

Then the "replace" function would automatically rebuild the type.

Josh Berkus
PostgreSQL @ Sun
San Francisco

In response to


pgsql-hackers by date

Next:From: Josh BerkusDate: 2006-05-24 01:21:12
Subject: Re: Why is CVS server so slow?
Previous:From: John JawedDate: 2006-05-24 00:30:17
Subject: Improving ALTER TYPE support

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group