Search Postgresql Archives

Re: pg_restore --clean failing due to dependancies

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Le 15/11/2016 à 16:21, Adrian Klaver a écrit :
The restore fails on a lot of statements, complaining about dependencies.
For instance, "cannot drop rule _RETURN on view myview1 because view
myview1requires it". Or "cannot drop constraint mypkey on table my table
because other objects depend on it [list of foreign keys]".

So where are the above objects, eg what schema?

They are in a schema that is included in the dump (more precisely, not excluded from).
It happens in all schemas, not a specific one.

pg_restore  -l  "D:\db.dump"
to see what pg_restore thinks is the order of restore.

OK I did that.
The output is pretty big.
The second error is a consequence of the first one (they were not foreign keys but views, sorry for the mistake). So the very first error from pg_restore, the "cannot drop rule _return..." is TOC 11330. It is on the line 4948 in the pg_restore -l output (does this order matter, or is it the TOC ?). The view is number 1467 in the TOC, and is on line 2353 of the pg_restore -l output.


--
Arnaud


--
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux