X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id B97595381A for ; Thu, 7 Apr 2005 17:04:41 +0100 (BST) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 23310-02 for ; Thu, 7 Apr 2005 16:04:36 +0000 (GMT) Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by svr1.postgresql.org (Postfix) with ESMTP id BEE77537EB for ; Thu, 7 Apr 2005 17:04:35 +0100 (BST) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.13.1/8.13.1) with ESMTP id j37G4Yi6003304; Thu, 7 Apr 2005 12:04:34 -0400 (EDT) To: "Joel Fradkin" Cc: "PostgreSQL Perform" Subject: Re: Any way to speed this up? In-reply-to: <005301c53b84$6b83f8a0$797ba8c0@jfradkin> References: <005301c53b84$6b83f8a0$797ba8c0@jfradkin> Comments: In-reply-to "Joel Fradkin" message dated "Thu, 07 Apr 2005 11:13:57 -0400" Date: Thu, 07 Apr 2005 12:04:34 -0400 Message-ID: <3303.1112889874@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.006 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200504/163 X-Sequence-Number: 11560 "Joel Fradkin" writes: > Running this explain on windows box, but production on linux both 8.0.1 Are you using any nondefault optimizer settings? The vast bulk of the time is going into the indexscan on tblassociate (almost 42 out of the 48 seconds), and I'm a bit surprised it didn't choose a seqscan and sort instead. Or even more likely, forget the merge joins altogether and use hash joins --- the other tables are plenty small enough to fit in hash tables. regards, tom lane