X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id CC20B53ACE; Fri, 1 Apr 2005 23:36:46 +0100 (BST) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 81875-07; Fri, 1 Apr 2005 22:36:44 +0000 (GMT) Received: from gw.tssi.com (gw.tssi.com [198.147.197.1]) by svr1.postgresql.org (Postfix) with ESMTP id 3FA5A53AB4; Fri, 1 Apr 2005 23:36:41 +0100 (BST) Received: from gw.tssi.com (nolan@gw.tssi.com [127.0.0.1] (may be forged)) by gw.tssi.com (8.12.6/8.12.6) with ESMTP id j31ManZE009304; Fri, 1 Apr 2005 16:36:50 -0600 Received: (from nolan@localhost) by gw.tssi.com (8.12.6/8.12.6/Submit) id j31MamDD009302; Fri, 1 Apr 2005 16:36:48 -0600 From: Mike Nolan Message-Id: <200504012236.j31MamDD009302@gw.tssi.com> Subject: Re: Sustained inserts per sec ... ? To: tgl@sss.pgh.pa.us (Tom Lane) Date: Fri, 1 Apr 2005 16:36:47 -0600 (CST) Cc: scrappy@postgresql.org (Marc G. Fournier), pgsql-performance@postgresql.org In-Reply-To: <28575.1112389417@sss.pgh.pa.us> from "Tom Lane" at Apr 01, 2005 04:03:37 PM X-Mailer: ELM [version 2.5 PL3] MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0 tagged_above=0 required=5 tests= X-Spam-Level: X-Archive-Number: 200504/25 X-Sequence-Number: 11422 > > Well, I just did an insert of 27,500 records with 9 fields, averaging > > around 118 bytes per record, each insert statement coming from a separate > > SQL statement fed to psql, and it took a bit over 4 minutes, or about > > 106 inserts per second. > > Is that with a separate transaction for each insert command? I can get > significantly higher rates on my devel machine if the inserts are > bundled into transactions of reasonable length. That's with autocommit on. If I do it as a single transaction block, it takes about 6.5 seconds, which is about 4200 transactions/second. -- Mike Nolan