Tom Lane wrote:
> Alvaro Herrera <alvherre@2ndquadrant.com> writes:
> > I think it'd be a good idea to add some more discoverability: what would
> > be deleted if an object X were to be deleted?
>
> There's plenty of discoverability already. The documentation suggests
>
> (If you want to check what <command>DROP ... CASCADE</> will do,
> run <command>DROP</> without <literal>CASCADE</> and read the
> <literal>DETAIL</> output.)
>
> Or you could do BEGIN; DROP ... CASCADE; ROLLBACK.
True, but the DETAIL is capped at 100 objects (per
reportDependentObjects); also, object locks need to be acquired, which
can be very troublesome if you discover that some frequently-used object
is in the set to be dropped, by some unfortunate accident.
--
Álvaro Herrera http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services