Altering a column type w/o dropping views

From: Ow Mun Heng <Ow(dot)Mun(dot)Heng(at)wdc(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Altering a column type w/o dropping views
Date: 2008-07-07 09:53:58
Message-ID: 1215424438.4952.46.camel@neuromancer.home.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I'm going to alter a bunch a tables columns's data type and I'm being
forced to drop a view which depends on the the colum.

eg: ALTER TABLE xs.d_trh ALTER m_dcm TYPE character varying;
ERROR: cannot alter type of a column used by a view or rule
DETAIL: rule _RETURN on view v_hpp depends on column "m_dcm"

Is there an alternative method of doing this w/o dropping the existing
view?

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Jack Brown 2008-07-07 11:54:45 Re: creating "a perfect sequence" column
Previous Message Dushyanth 2008-07-07 08:53:24 Re: [Postgresql 8.2.3] autovacuum starting up even after disabling ?