Received: from maia.hub.org (unknown [200.46.204.183]) by mail.postgresql.org (Postfix) with ESMTP id 914D46322FA for ; Mon, 5 Apr 2010 04:57:07 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 62011-04 for ; Mon, 5 Apr 2010 07:56:56 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-ew0-f220.google.com (mail-ew0-f220.google.com [209.85.219.220]) by mail.postgresql.org (Postfix) with ESMTP id BD6346322C3 for ; Mon, 5 Apr 2010 04:56:56 -0300 (ADT) Received: by ewy20 with SMTP id 20so1254895ewy.21 for ; Mon, 05 Apr 2010 00:56:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:received:message-id:subject:from:to:cc:content-type; bh=oTlafUuP4VAwiAnjFrbhJHTzkwq+6HitIjjKd0Zjf8o=; b=IqoI89R1zlP2L+de2IYZHjzuhqp7wK0t2Ssv+KHCnOWv3gLP7yFijFL4gsrRyHpO6V 9vx3RxaZHQZFa2y1Ie4vylsoDUmWmsKWk6isommuvzmtI/0v92iAuOH54PBls4GkMgil EHaFHBmONZqUscRLk055Ge2zIHWsqkmVhjEL4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=H6gSq3Tgf5P9IERkKO03pJvoUbe7c4G2ql2Bk22JhLkdr8OkLwt5QLr/AzEU+0/2wM ILxxwBJmgYzE4VXt0wP08SCtoRjI72l4Hv1sU3fFUiAG0EYAI0nPgd+cNt6TgltqeTTi Gge5fycbxRI2LJmfVZ/hzHdclUr2c0kuZItPo= MIME-Version: 1.0 Received: by 10.213.32.73 with HTTP; Mon, 5 Apr 2010 00:56:54 -0700 (PDT) In-Reply-To: <201004010044.o310iPU08826@momjian.us> References: <26236.1269971456@sss.pgh.pa.us> <201004010044.o310iPU08826@momjian.us> Date: Mon, 5 Apr 2010 11:56:54 +0400 Received: by 10.213.73.65 with SMTP id p1mr2718038ebj.65.1270454215011; Mon, 05 Apr 2010 00:56:55 -0700 (PDT) Message-ID: Subject: Re: temp table "on commit delete rows": transaction overhead From: Artiom Makarov To: Bruce Momjian Cc: Tom Lane , pgsql-performance@postgresql.org Content-Type: text/plain; charset=ISO-8859-1 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-2.599 tagged_above=-10 required=5 tests=BAYES_00=-2.599 X-Spam-Level: X-Archive-Number: 201004/53 X-Sequence-Number: 38303 2010/4/1 Bruce Momjian : > I think one of the problems is that we do the truncate even if the table > has not be touched by the query, which is poor behavior. Thank you for the support. Will be this problem registered? PS I see a workaround: switch off "on commit delete rows" on temp tables and use txid_current() to control transaction visibility.