Re: Insert performance for large transaction with multiple COPY FROM

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Insert performance for large transaction with multiple COPY FROM
Дата
Msg-id 24687.1358029611@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Insert performance for large transaction with multiple COPY FROM  (Jeff Janes <jeff.janes@gmail.com>)
Список pgsql-performance
Jeff Janes <jeff.janes@gmail.com> writes:
> Will PG allow you to add a FK constraint where there is no usable
> index on the referenced side?

It will not, because the referenced side must have a unique constraint,
ie an index.

The standard performance gotcha here is not having an index on the
referencing side.  But that only hurts when doing UPDATEs/DELETEs of
referenced-side keys, which as far as I gathered was not the OP's
scenario.

            regards, tom lane


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

Предыдущее
От: Claudio Freire
Дата:
Сообщение: Re: Insert performance for large transaction with multiple COPY FROM
Следующее
От: Horst Dehmer
Дата:
Сообщение: Re: Insert performance for large transaction with multiple COPY FROM