Re: batch inserts are "slow"

Поиск
Список
Период
Сортировка
От Christopher Petrilli
Тема Re: batch inserts are "slow"
Дата
Msg-id 59d991c4050503121725619c6d@mail.gmail.com
обсуждение исходный текст
Ответ на Re: batch inserts are "slow"  (Tim Terlegård <tim@se.linux.org>)
Список pgsql-performance
On 5/3/05, Tim Terlegård <tim@se.linux.org> wrote:
> > Just as on Oracle you would use SQL*Loader for this application, you
> > should use the COPY syntax for PostgreSQL.  You will find it a lot
> > faster.  I have used it by building the input files and executing
> > 'psql' with a COPY command, and also by using it with a subprocess,
> > both are quite effective.
>
> I tried this now. Now it's down to 0.45 seconds. It feels a bit hacky to
> run /usr/bin/psql from java, but it sure works. Thanks for the hint!

It may feel hacky, but I think if you want to use SQL*Loader on
Oracle, you have to do the same thing.  I know a C++ app that I use
that runs SQL*Loader about once per second to deal with a HUGE volume
(10K/sec).  In fact, moving the load files onto ramdisk has helped a
lot.

Chris
--
| Christopher Petrilli
| petrilli@gmail.com

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

Предыдущее
От: Mischa Sandberg
Дата:
Сообщение: Re: COPY vs INSERT
Следующее
От: Dave Cramer
Дата:
Сообщение: Re: batch inserts are "slow"