Re: find all views depend on a schema/table

From: Emi Lu <emilu(at)encs(dot)concordia(dot)ca>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-sql <pgsql-sql(at)postgresql(dot)org>
Subject: Re: find all views depend on a schema/table
Date: 2014-01-24 17:04:11
Message-ID: 52E29D0B.4000201@encs.concordia.ca
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

>> Is there a simple way to query all views depend on a schema or table?
> Well, you could build something that examines pg_depend, or you could
> try this:

Thank you. I will try to find mapped results for pg_depend.

> begin;
> drop table some_table restrict;
> ... note what it complains about ...
> rollback;

No... to find all views(not in schema1) depend on any schema1.objects.

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message bobspero 2014-01-27 00:17:26 Detecting when field value changes in Foreign Table?
Previous Message Adrian Klaver 2014-01-24 16:48:00 Re: consulting the question about the usage about SSH Tunnel function