X-Original-To: pgsql-admin-postgresql.org@postgresql.org Received: from localhost (wm.hub.org [200.46.204.128]) by postgresql.org (Postfix) with ESMTP id 6F95E9FB349 for ; Wed, 23 Aug 2006 12:00:10 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.128]) (amavisd-new, port 10024) with ESMTP id 58795-07 for ; Wed, 23 Aug 2006 14:59:50 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey- Received: from lists.commandprompt.com (host-130.commandprompt.net [207.173.203.130]) by postgresql.org (Postfix) with ESMTP id 4F7099FB1EF for ; Wed, 23 Aug 2006 11:59:47 -0300 (ADT) Received: from [192.168.1.50] (or-67-76-146-141.sta.embarqhsd.net [67.76.146.141]) (authenticated bits=0) by lists.commandprompt.com (8.13.7/8.13.6) with ESMTP id k7NExlkq004994 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 23 Aug 2006 07:59:48 -0700 Message-ID: <44EC6D63.4020507@commandprompt.com> Date: Wed, 23 Aug 2006 07:59:47 -0700 From: "Joshua D. Drake" Organization: Command Prompt, Inc. User-Agent: Thunderbird 1.5.0.5 (X11/20060728) MIME-Version: 1.0 To: Thor Tall CC: pgsql-admin@postgresql.org Subject: Re: Slow delete/insert. References: <20060823143017.98255.qmail@web50301.mail.yahoo.com> In-Reply-To: <20060823143017.98255.qmail@web50301.mail.yahoo.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: ClamAV version 0.88.3, clamav-milter version 0.88.3 on projects.commandprompt.com X-Virus-Status: Clean X-Greylist: Sender succeded SMTP AUTH authentication, not delayed by milter-greylist-1.6 (lists.commandprompt.com [192.168.2.159]); Wed, 23 Aug 2006 07:59:48 -0700 (PDT) X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=3.951 tagged_above=0 required=5 tests=FORGED_RCVD_HELO, SPF_HELO_SOFTFAIL, SPF_SOFTFAIL X-Spam-Level: *** X-Archive-Number: 200608/247 X-Sequence-Number: 22790 > It takes 6 minutes to ingest the data with an empty > database and 25 minutes (wall time) if all the data is > already in the database. > The processing is done as follows: > 1. Start transaction > > 2. check if message is in table 1 and if so delete > records from table 1(1 row),2(2 rows),3(30 rows),4(50 > rows). > > 3. split the message and insert the date in table 1(1 > row),2(2 rows),3(30 rows),4(50 rows) > > 4. end transaction Put more inserts into a single transaction > > I need some suggestions so that I can ingest the data > faster. with the same computer and disks. We are > running redhat 7.2 on the server and I am using the c > interface to write the data to the server. What version of PostgreSQL? Joshua D. Drake > > Thanks for any help, > Thor. > > __________________________________________________ > Do You Yahoo!? > Tired of spam? Yahoo! Mail has the best spam protection around > http://mail.yahoo.com > > ---------------------------(end of broadcast)--------------------------- > TIP 5: don't forget to increase your free space map settings > -- === The PostgreSQL Company: Command Prompt, Inc. === Sales/Support: +1.503.667.4564 || 24x7/Emergency: +1.800.492.2240 Providing the most comprehensive PostgreSQL solutions since 1997 http://www.commandprompt.com/