Re: Alter view with dependence without drop view!

From: Thomas Kellerer <spam_eater(at)gmx(dot)net>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Alter view with dependence without drop view!
Date: 2018-01-30 22:03:18
Message-ID: p4qpv8$b1p$1@blaine.gmane.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: 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, what is 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 table columns 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

In response to

Browse pgsql-general by date

  From Date Subject
Next Message David G. Johnston 2018-01-30 22:14:33 Re: Working with JSONB data having node lists
Previous Message Tomas Vondra 2018-01-30 22:00:29 Re: ERROR: invalid memory alloc request size 1073741824