Re: pg_restore and FK constraints with large dbs

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: pg_restore and FK constraints with large dbs
Дата
Msg-id Pine.LNX.4.44.0311140043230.17499-100000@peter.localdomain
обсуждение исходный текст
Ответ на Re: pg_restore and FK constraints with large dbs  (ow <oneway_111@yahoo.com>)
Ответы Re: pg_restore and FK constraints with large dbs  (ow <oneway_111@yahoo.com>)
Re: pg_restore and FK constraints with large dbs  (ow <oneway_111@yahoo.com>)
Список pgsql-admin
ow writes:

> Can you clarify how this would be better than the second option I described?
> Unless pg_restore can somehow create FK constraints differently (and more
> efficiently) than using "ALTER TABLE xxx ADD CONSTRAINT", I do not see how this
> would help.

If you you pg_dump and dump schema and data together, then there is some
magic to temporarily disable foreign key constraints.  Try it out.
Perhaps you can adopt the statements to your particular restoration method
as well, if it turns out necessary.

--
Peter Eisentraut   peter_e@gmx.net


В списке pgsql-admin по дате отправления:

Предыдущее
От: ow
Дата:
Сообщение: Re: pg_restore and FK constraints with large dbs
Следующее
От: Tom Lane
Дата:
Сообщение: Re: dropped users appear as numbers in ACL