Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id 306631337B61 for ; Fri, 25 Mar 2011 09:24:04 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 06754-02 for ; Fri, 25 Mar 2011 12:23:56 +0000 (UTC) X-Greylist: delayed 00:27:34.779941 by SQLgrey-1.7.6 Received: from 10610.x.rootbsd.net (10610.x.rootbsd.net [204.109.60.69]) by mail.postgresql.org (Postfix) with ESMTP id 2C54D133616B for ; Fri, 25 Mar 2011 09:23:56 -0300 (ADT) Received: from [192.168.1.105] (localhost [127.0.0.1]) by 10610.x.rootbsd.net (8.14.3/8.14.3) with ESMTP id p2PBxTKW023272; Fri, 25 Mar 2011 11:59:30 GMT (envelope-from gandalf@shopzeus.com) Message-ID: <4D8C82DE.7060601@shopzeus.com> Date: Fri, 25 Mar 2011 12:56:14 +0100 From: Laszlo Nagy User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.14) Gecko/20110223 Thunderbird/3.1.8 MIME-Version: 1.0 To: Marti Raudsepp CC: pgsql-performance@postgresql.org, Daniel Fekete Subject: Re: Slow query on CLUTER -ed tables References: <4D8A581C.6040505@shopzeus.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.9 tagged_above=-10 required=5 tests=BAYES_00=-1.9 X-Spam-Level: X-Archive-Number: 201103/331 X-Sequence-Number: 43010 > I suspect that, since the matched hid's probably aren't sequential, > many of those ~500 product_price_offer_history rows will be far apart > on disk. OMG I was a fool! I'll CLUSTER on a different index and it will be fast, I'm sure. Thanks! L