Re: suggestion

Поиск
Список
Период
Сортировка
От Lukas Smith
Тема Re: suggestion
Дата
Msg-id dtmcdm$3kd$1@news.hub.org
обсуждение исходный текст
Ответ на Re: suggestion  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
Tom Lane wrote:

> worse --- in the first place there are severe performance issues
> associated with unindexed foreign-key checks, and in the second place
> there is the foot-gun problem that you might forget to re-add the
> indexes at all.

MySQL has a syntax in ALTER TABLE similar to PGSQL's DISABLE/ENABLE 
TRIGGER to do the same for KEYS. That way you will not run the risk of 
forgetting the INDEX (though you could still forget to enable them).

Potentially there could be a switch in pg_restore to create all KEYS as 
disabled initially and automatically enable them after the import is 
complete. Note that it could be smart enough to give special treatment 
to foreign keys.

regards,
Lukas


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

Предыдущее
От: Michael Glaesemann
Дата:
Сообщение: Re: PostgreSQL unit tests
Следующее
От: Simon Riggs
Дата:
Сообщение: Re: memory context for tuplesort return values