Re: LOCK TABLE & speeding up mass data loads - Mailing list pgsql-performance

From Curt Sampson
Subject Re: LOCK TABLE & speeding up mass data loads
Date
Msg-id Pine.NEB.4.51.0301270808260.596@angelic.cynic.net
Whole thread Raw
In response to Re: LOCK TABLE & speeding up mass data loads  (Ron Johnson <ron.l.johnson@cox.net>)
Responses Re: LOCK TABLE & speeding up mass data loads
List 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 by date:

Previous
From: Medve Gabor
Date:
Subject: bigserial vs serial - which one I'd have to use?
Next
From: Bruce Momjian
Date:
Subject: Re: [GENERAL] optimizing query