Re: insert vs select into performance

From: Michael Stone <mstone+postgres(at)mathom(dot)us>
To: Thomas Finneid <tfinneid(at)student(dot)matnat(dot)uio(dot)no>
Cc: pgsql-performance(at)postgresql(dot)org
Subject: Re: insert vs select into performance
Date: 2007-07-17 20:58:35
Message-ID: 20070717205832.GB12481@mathom.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

On Tue, Jul 17, 2007 at 10:50:22PM +0200, Thomas Finneid wrote:
>I havent done this test in a stored function yet, nor have I tried it
>with a C client so far, so there is the chance that it is java/jdbc that
>makes the insert so slow. I'll get to that test soon if there is any
>chance my theory makes sence.

What you're seeing is perfectly normal. Switch to COPY for fast inserts.
(When you use inserts you need to wait for a round-trip for each row,
instead of sending data to the server as fast as possible.)

Mike Stone

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message Mark Lewis 2007-07-17 20:59:28 Re: insert vs select into performance
Previous Message Thomas Finneid 2007-07-17 20:58:01 Re: insert vs select into performance