Received: from localhost (maia-4.hub.org [200.46.204.183]) by postgresql.org (Postfix) with ESMTP id 7AC9E9FB279 for ; Tue, 13 Mar 2007 10:30:03 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-new, port 10024) with ESMTP id 71000-02 for ; Tue, 13 Mar 2007 10:29:32 -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 4542F9FB6FA for ; Tue, 13 Mar 2007 10:29:32 -0300 (ADT) Received: from rly28b.srv.mailcontrol.com (localhost.localdomain [127.0.0.1]) by rly28b.srv.mailcontrol.com (MailControl) with ESMTP id l2DDTOSD019370 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Tue, 13 Mar 2007 13:29:26 GMT Received: from submission.mailcontrol.com (submission.mailcontrol.com [86.111.216.190]) by rly28b.srv.mailcontrol.com (MailControl) id l2DDSdgW017327 for pgsql-performance@postgresql.org; Tue, 13 Mar 2007 13:28:39 GMT Received: from mail.leroymerlin.fr (lewebquivabien.leroymerlin.fr [195.25.212.55]) by rly28b-eth0.srv.mailcontrol.com (envelope-sender vincent.moreau@leroymerlin.fr) (MIMEDefang) with ESMTP id l2DDSV2v016942; Tue, 13 Mar 2007 13:28: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 2007031314201264:1681403 ; Tue, 13 Mar 2007 14:20:12 +0100 Received: from [10.2.50.136] ([10.2.50.136]) by cmailf1.corp.leroymerlin.com (MOS 3.8.2-GA) with ESMTP id BHL00502 (AUTH vincent.moreau@leroymerlin.fr); Tue, 13 Mar 2007 14:27:55 +0100 (WAT) Message-ID: <45F6A6F8.9090405@leroymerlin.fr> Date: Tue, 13 Mar 2007 14:28:24 +0100 From: Organization: leroy merlin User-Agent: Thunderbird 1.5.0.10 (X11/20070306) MIME-Version: 1.0 To: vincent.moreau@leroymerlin.fr, 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> In-Reply-To: <20070313130945.GB4490@alvh.no-ip.org> X-MIMETrack: Itemize by SMTP Server on DMZSMTP/France/Leroy Merlin(Release 5.0.13a |April 8, 2004) at 13/03/2007 14:20:12, Serialize by Router on DMZSMTP/France/Leroy Merlin(Release 5.0.13a |April 8, 2004) at 13/03/2007 14:20:16, Serialize complete at 13/03/2007 14:20:16 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=iso-8859-1 X-Scanned-By: MailControl A-07-06-90 (www.mailcontrol.com) on 10.66.1.138 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200703/220 X-Sequence-Number: 23625 Here it is : CCM=3D# SHOW enable_mergejoin; enable_mergejoin ------------------ on (1 row) CCM=3D# Alvaro Herrera wrote: > vincent.moreau@leroymerlin.fr wrote: >=20=20=20 >> I have attached the requested information. >> >> You will see that the query is quite messy and could be easily improved. >> Unfortunately, it came from a third party application and we do not have= =20 >> access to the source code. >>=20=20=20=20=20 > > There are only nested loops and hash joins, while the other plan seems > to be more elaborate -- I wonder if you have disabled bitmap scan, merge > joins, in 8.2? Try a SHOW enable_mergejoin in psql. > >=20=20=20 Ce message et toutes les pi=E8ces jointes sont =E9tablis =E0 l'attention ex= clusive de leurs destinataires et sont confidentiels. Si vous recevez ce me= ssage par erreur, merci de le d=E9truire et d'en avertir imm=E9diatement l'= exp=E9diteur. L'internet ne permettant pas d'assurer l'int=E9grit=E9 de ce = message, le contenu de ce message ne repr=E9sente en aucun cas un engagemen= t de la part de Leroy Merlin.