Received: from localhost (unknown [200.46.204.183]) by postgresql.org (Postfix) with ESMTP id C8F5A2E0264 for ; Wed, 12 Mar 2008 14:34:13 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 88115-04 for ; Wed, 12 Mar 2008 14:33:59 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from mail01.enterprisedb.com (webmail.enterprisedb.com [63.246.7.168]) by postgresql.org (Postfix) with ESMTP id 833922E313C for ; Wed, 12 Mar 2008 14:33:52 -0300 (ADT) thread-index: AciEZ1JwQsSk66Z3Q5OzDdP4EZHr+Q== Received: from [172.24.32.184] ([62.232.55.118]) by mail01.enterprisedb.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.3959); Wed, 12 Mar 2008 13:34:26 -0400 Content-Class: urn:content-classes:message Importance: normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.4133 Message-ID: <47D813FB.1000006@enterprisedb.com> Date: Wed, 12 Mar 2008 17:33:47 +0000 From: "Heikki Linnakangas" Organization: EnterpriseDB User-Agent: Mozilla-Thunderbird 2.0.0.9 (X11/20080110) MIME-Version: 1.0 To: "Pavan Deolasee" Cc: "Tom Lane" , "Craig Ringer" , "pgsql-patches" Subject: Re: [PERFORM] Very slow (2 tuples/second) sequential scan after bulk insert; speed returns to ~500 tuples/second after commit References: <47D505AF.4040101@postnewspapers.com.au> <47D54DB2.4020405@enterprisedb.com> <24304.1205162440@sss.pgh.pa.us> <47D67C3F.1030406@enterprisedb.com> <5827.1205269597@sss.pgh.pa.us> <47D7DE12.80700@enterprisedb.com> <2e78013d0803120847k2e8afbedrc39e29e5194d3c6e@mail.gmail.com> <19902.1205337439@sss.pgh.pa.us> <2e78013d0803121002o2b7a8531y1553ce66cb6d1537@mail.gmail.com> <47D80F5C.2060500@enterprisedb.com> <2e78013d0803121026r227bbebdr5189be193b4a1bf5@mail.gmail.com> In-Reply-To: <2e78013d0803121026r227bbebdr5189be193b4a1bf5@mail.gmail.com> Content-Type: text/plain; format=flowed; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 12 Mar 2008 17:34:26.0390 (UTC) FILETIME=[517FFF60:01C88467] X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200803/195 X-Sequence-Number: 5258 Pavan Deolasee wrote: > Wait. Subtransaction ids are local to a transaction and always start from 1. > See this: > > /* > * reinitialize within-transaction counters > */ > s->subTransactionId = TopSubTransactionId; > currentSubTransactionId = TopSubTransactionId; No, we're not talking about SubTransactionIds. We're talking about real XIDs assigned to subtransactions. Subtransactions are assigned regular XIDs as well, just like top-level transactions. I can see where you were coming from with you suggestion now :-). -- Heikki Linnakangas EnterpriseDB http://www.enterprisedb.com