Re: bulk inserts

From: Grzegorz Jaśkiewicz <gryzman(at)gmail(dot)com>
To: Dave Huber <DHuber(at)letourneautechnologies(dot)com>
Cc: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: bulk inserts
Date: 2009-09-29 14:35:59
Message-ID: 2f4958ff0909290735p640dd3e4r62987e786ea46070@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, Sep 29, 2009 at 3:31 PM, Dave Huber <
DHuber(at)letourneautechnologies(dot)com> wrote:

> All I have to say is wow! COPY works sooo much faster than the iterative
> method I was using. Even after having to read the entire binary file and
> reformat the data into the binary format that postgres needs it is an order
> of magnitude faster than using a prepared INSERT. At least that’s what my
> prelim testing is showing me. I will have to let it run for a while with a
> larger table to see how it performs in the longrun, but initially this is
> very positive.
>
you can also try wrapping whole bunch of inserts in a transaction block.

--
GJ

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2009-09-29 14:40:54 Re: query is taking longer time after a while
Previous Message Dave Huber 2009-09-29 14:31:58 Re: bulk inserts