How modify a sql-function without breaking views ?

From: Andreas <maps(dot)on(at)gmx(dot)net>
To: pgsql-novice(at)postgresql(dot)org
Subject: How modify a sql-function without breaking views ?
Date: 2009-03-20 17:34:10
Message-ID: 49C3D392.50409@gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

Hi,

I'm wondering how I might modify a sql-function without breaking views
that use it.
Basically the function gets called with a parameter and fetches a SETOF
type_X where type_X is a columnlist for the function's result.
The function joins a couple of tables to make some code-columns nicely
readable and selects some columns.

Later there are a growing number of views that need all those columns
from the function and join some other tables agains it.
Nothing impressive, yet.

But what can I do if I figure I'd like to have another column in this
function result?
To add it, I had to drop the type and recreate it.
This drops the function and with it go all subsequent views down the
drain. :(

Browse pgsql-novice by date

  From Date Subject
Next Message Richard Sickler 2009-03-24 17:08:21 Question on returning Rows in a stored proc
Previous Message David Saracini 2009-03-19 15:38:25 Re: Service start up error "The service name is invalid net helpmsg 2185"