From: Andreas Kretschmer <akretschmer@spamfence.net>
To: pgsql-performance@postgresql.org
Subject: Re: Very long SQL strings
Date: Thu, 21 Jun 2007 20:48:33 +0200
Message-ID: <20070621184833.GA10814@KanotixBox> (raw)
In-Reply-To: <357fa7590706211133u2ae43d09id1653ca63d7a7838@mail.gmail.com>
References: <357fa7590706211133u2ae43d09id1653ca63d7a7838@mail.gmail.com>
Steven Flatt <steven.flatt@gmail.com> schrieb:
> For example, on a toy table with two columns, I noticed about a 20% increase
> when bulking together 1000 tuples in one INSERT statement as opposed to doing
> 1000 individual INSERTS. Would this be the same for 10000? 100000? Does it
> depend on the width of the tuples or the data types?
I guess you can obtain the same if you pack all INSERTs into one
transaction.
And, faster than INSERT: COPY.
Andreas
--
Really, I'm not out to destroy Microsoft. That will just be a completely
unintentional side effect. (Linus Torvalds)
"If I was god, I would recompile penguin with --enable-fly." (unknow)
Kaufbach, Saxony, Germany, Europe. N 51.05082°, E 13.56889°
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: akretschmer@spamfence.net
Subject: Re: Very long SQL strings
In-Reply-To: <20070621184833.GA10814@KanotixBox>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox