Re: How to improve insert speed with index on text column

Поиск
Список
Период
Сортировка
От Andy Colson
Тема Re: How to improve insert speed with index on text column
Дата
Msg-id 4F26E25C.1020402@squeakycode.net
обсуждение исходный текст
Ответ на How to improve insert speed with index on text column  (Saurabh <saurabh.b85@gmail.com>)
Список pgsql-performance
On 1/30/2012 3:27 AM, Saurabh wrote:
> Hi all,
>
> I am using Postgresql database for our project and doing some
> performance testing. We need to insert millions of record with indexed
> columns. We have 5 columns in table. I created index on integer only
> then performance is good but when I created index on text column as
> well then the performance reduced to 1/8th times. My question is how I
> can improve performance when inserting data using index on text
> column?
>
> Thanks,
> Saurabh
>

Do it in a single transaction, and use COPY.

-Andy

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

Предыдущее
От: Claudio Freire
Дата:
Сообщение: Re: How to improve insert speed with index on text column
Следующее
От: Alessandro Gagliardi
Дата:
Сообщение: Why should such a simple query over indexed columns be so slow?