Re: LOCK TABLE & speeding up mass data loads

Поиск
Список
Период
Сортировка
От Curt Sampson
Тема Re: LOCK TABLE & speeding up mass data loads
Дата
Msg-id Pine.NEB.4.51.0301270808260.596@angelic.cynic.net
обсуждение исходный текст
Ответ на Re: LOCK TABLE & speeding up mass data loads  (Ron Johnson <ron.l.johnson@cox.net>)
Ответы Re: LOCK TABLE & speeding up mass data loads  (Ron Johnson <ron.l.johnson@cox.net>)
Список pgsql-performance
On Sun, 25 Jan 2003, Ron Johnson wrote:

> > Oh, and you're using COPY right?
>
> No.  Too much data manipulation to do 1st.  Also, by committing every
> X thousand rows, then if the process must be aborted, then there's
> no huge rollback, and the script can then skip to the last comitted
> row and pick up from there.

I don't see how the amount of data manipulation makes a difference.
Where you now issue a BEGIN, issue a COPY instead. Where you now INSERT,
just print the data for the columns, separated by tabs. Where you now
issue a COMMIT, end the copy.

cjs
--
Curt Sampson  <cjs@cynic.net>   +81 90 7737 2974   http://www.netbsd.org
    Don't you know, in this new Dark Age, we're all light.  --XTC

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

Предыдущее
От: Medve Gabor
Дата:
Сообщение: bigserial vs serial - which one I'd have to use?
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: [GENERAL] optimizing query