Re: Can one turn off constraints/indices temporarily?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Can one turn off constraints/indices temporarily?
Дата
Msg-id 12993.1138892232@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Can one turn off constraints/indices temporarily?  (<kynn@panix.com>)
Список pgsql-novice
<kynn@panix.com> writes:
> Now, suppose that one had to insert many records at once.  Is it
> possible to mimic the above strategy by turning off the constraints
> and indexing temporarily (without dropping them altogether), and
> turning them back on after all the inserts have been made.

No.  You can drop and re-add them if you have a mind to.  People
do this fairly often with indexes and foreign key constraints ---
there's no advantage in doing it for CHECK constraints though.

            regards, tom lane

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

Предыдущее
От:
Дата:
Сообщение: Can one turn off constraints/indices temporarily?
Следующее
От: Michael Swierczek
Дата:
Сообщение: pg_dump - sort data?