Received: from localhost (maia-3.hub.org [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id E7CB09FA4C1 for ; Tue, 13 Mar 2007 12:48:29 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-new, port 10024) with ESMTP id 50379-03 for ; Tue, 13 Mar 2007 12:48:12 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.4 Received: from cluster-b.mailcontrol.com (cluster-b.mailcontrol.com [217.68.146.190]) by postgresql.org (Postfix) with ESMTP id D3C0B9FA4BB for ; Tue, 13 Mar 2007 12:48:18 -0300 (ADT) Received: from rly01b.srv.mailcontrol.com (localhost.localdomain [127.0.0.1]) by rly01b.srv.mailcontrol.com (MailControl) with ESMTP id l2DFmGvh020462 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Tue, 13 Mar 2007 15:48:16 GMT Received: from submission.mailcontrol.com (submission.mailcontrol.com [86.111.216.190]) by rly01b.srv.mailcontrol.com (MailControl) id l2DFldPr019399 for pgsql-performance@postgresql.org; Tue, 13 Mar 2007 15:47:39 GMT Received: from mail.leroymerlin.fr (lewebquivabien.leroymerlin.fr [195.25.212.55]) by rly01b-eth0.srv.mailcontrol.com (envelope-sender vincent.moreau@leroymerlin.fr) (MIMEDefang) with ESMTP id l2DFl8we018783; Tue, 13 Mar 2007 15:47:39 +0000 (GMT) Received: from cmailf1.corp.leroymerlin.com ([10.5.3.20]) by mail.leroymerlin.fr (Lotus Domino Release 5.0.13a) with ESMTP id 2007031316384591:1683808 ; Tue, 13 Mar 2007 16:38:45 +0100 Received: from [10.2.50.136] ([10.2.50.136]) by cmailf1.corp.leroymerlin.com (MOS 3.8.2-GA) with ESMTP id BHR00060 (AUTH vincent.moreau@leroymerlin.fr); Tue, 13 Mar 2007 16:46:09 +0100 (WAT) Message-ID: <45F6C75A.4070407@leroymerlin.fr> Date: Tue, 13 Mar 2007 16:46:34 +0100 From: Organization: leroy merlin User-Agent: Thunderbird 1.5.0.10 (X11/20070306) MIME-Version: 1.0 To: Tom Lane CC: Michael Fuhr , pgsql-performance@postgresql.org Subject: Re: Execution plan changed after upgrade from 7.3.9 to 8.2.3 References: <45F65EA3.1030706@leroymerlin.fr> <20070313101117.GA98241@winnie.fuhr.org> <45F686FA.2090909@leroymerlin.fr> <20070313130945.GB4490@alvh.no-ip.org> <45F6A6F8.9090405@leroymerlin.fr> <20070313134306.GC6715@alvh.no-ip.org> <45F6AFA9.4020804@leroymerlin.fr> <2335.1173798373@sss.pgh.pa.us> In-Reply-To: <2335.1173798373@sss.pgh.pa.us> X-MIMETrack: Itemize by SMTP Server on DMZSMTP/France/Leroy Merlin(Release 5.0.13a |April 8, 2004) at 13/03/2007 16:38:45, Serialize by Router on DMZSMTP/France/Leroy Merlin(Release 5.0.13a |April 8, 2004) at 13/03/2007 16:39:19, Serialize complete at 13/03/2007 16:39:19 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=ISO-8859-1; format=flowed X-Scanned-By: MailControl A-07-06-90 (www.mailcontrol.com) on 10.66.1.111 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200703/231 X-Sequence-Number: 23636 Thanks for the advice Tom ! Setting enable_nestloop = off did improve the query a much better way than setting enable_seqscan to off. It does not screw the costs either (I had very odd costs with enable_seqscan to off like this : Nested Loop (cost=400001665.30..400002197.96 rows=1 width=96) Is there a "performance risk" to have enable_nestloop = off for other queries ? If I had the choice, should I go for index creation for the specific tables or should I tweak the optimizer with enable_nestloop = off ? Thanks again to all of you for your help. Best Regards, Vincent Tom Lane wrote: > writes: > >> I was able to improve response time by seting enable_seqscan to off >> > > enable_nestloop = off would probably be a saner choice, at least for > this particular query. > > regards, tom lane > > ---------------------------(end of broadcast)--------------------------- > TIP 3: Have you checked our extensive FAQ? > > http://www.postgresql.org/docs/faq > > Ce message et toutes les pièces jointes sont établis à l'attention exclusive de leurs destinataires et sont confidentiels. Si vous recevez ce message par erreur, merci de le détruire et d'en avertir immédiatement l'expéditeur. L'internet ne permettant pas d'assurer l'intégrité de ce message, le contenu de ce message ne représente en aucun cas un engagement de la part de Leroy Merlin.