Re: Alter view with dependence without drop view! - Mailing list pgsql-general

From Thomas Kellerer
Subject Re: Alter view with dependence without drop view!
Date
Msg-id p4qpv8$b1p$1@blaine.gmane.org
Whole thread Raw
In response to Alter view with dependence without drop view!  (Elson Vaz <elsonlei@gmail.com>)
List pgsql-general
Elson Vaz schrieb am 30.01.2018 um 14:40:
> Hello!
> 
> I want make change in one view that have dependence view's, so when i try to make change i'm block because of this,
whatis the best solution??
 
> 

This can easily be dealt with when using a schema management tool.

We use Liquibase for this and the main migration script simply drops all views before running any migration (so that
tablecolumns can be removed or renamed without having to think about view dependencies).
 

Once the table migrations are done, all views are re-created automatically.

The Liquibase migration script and the SQL source for the views are stored together in Git.

Thomas






pgsql-general by date:

Previous
From: Tomas Vondra
Date:
Subject: Re: ERROR: invalid memory alloc request size 1073741824
Next
From: "David G. Johnston"
Date:
Subject: Re: Working with JSONB data having node lists