Re: DROP SCHEMA xxx CASCADE: ERROR: could not open relation with OID yyy
От | strk |
---|---|
Тема | Re: DROP SCHEMA xxx CASCADE: ERROR: could not open relation with OID yyy |
Дата | |
Msg-id | 20110207141436.GG34837@keybit.net обсуждение исходный текст |
Ответ на | Re: DROP SCHEMA xxx CASCADE: ERROR: could not open relation with OID yyy (strk <strk@keybit.net>) |
Список | pgsql-hackers |
I've uploaded also the script output ( CASCADE traces ) : http://strk.keybit.net/tmp/could_not_open_relation.sqlhttp://strk.keybit.net/tmp/could_not_open_relation.log And realized that the relation oid is the one first requested for deletion. Ie: DROP TABLE XXX CASCADE;..ERROR: could not open relation with OID XXX:regclass::oid I've found two ways to avoid the error: 1. Perform the DROP TABLE outside the transaction triggering its creation 2. Avoiding population of the table being dropped (the AddEdge call) Note that the 'edge_data' table has a foreign key to itself, and the constraint is initially deferred (may have a role here, I guess ?) "next_left_edge_exists" FOREIGN KEY (abs_next_left_edge) REFERENCES.edge_data(edge_id) DEFERRABLE INITIALLYDEFERRED, "next_right_edge_exists" FOREIGN KEY (abs_next_right_edge) REFERENCES edge_data(edge_id) DEFERRABLE INITIALLY DEFERRED --strk; () Free GIS & Flash consultant/developer /\ http://strk.keybit.net/services.html
В списке pgsql-hackers по дате отправления: