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 52D9F56814 for ; Tue, 22 Mar 2005 20:07:44 +0000 (GMT) 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 60514-05 for ; Tue, 22 Mar 2005 20:07:43 +0000 (GMT) Received: from quasar.skima.is (quasar.skima.is [212.30.200.205]) by svr1.postgresql.org (Postfix) with ESMTP id 6C974567B2 for ; Tue, 22 Mar 2005 20:07:41 +0000 (GMT) Received: from gnari ([157.157.159.208] [157.157.159.208]) by quasar.skima.is with ESMTP; Tue, 22 Mar 2005 20:07:40 Z Subject: Re: Planner issue From: Ragnar =?ISO-8859-1?Q?Hafsta=F0?= To: Alex Turner Cc: "Joshua D. Drake" , "pgsql-performance@postgresql.org" In-Reply-To: <33c6269f05032211366ce4563b@mail.gmail.com> References: <33c6269f05032206565ca4f9f1@mail.gmail.com> <42404663.2010504@commandprompt.com> <33c6269f05032211366ce4563b@mail.gmail.com> Content-Type: text/plain Date: Tue, 22 Mar 2005 20:09:03 +0000 Message-Id: <1111522143.7726.48.camel@localhost.localdomain> Mime-Version: 1.0 X-Mailer: Evolution 2.0.2 Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.001 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200503/466 X-Sequence-Number: 11171 On Tue, 2005-03-22 at 14:36 -0500, Alex Turner wrote: > I will use an index 220-300, but not 200-300. > ... > Seq Scan on propmain (cost=0.00..15517.56 rows=6842 width=4) (actual > time=0.039..239.760 rows=6847 loops=1) > ... > Index Scan using propmain_listprice_i on propmain > (cost=0.00..22395.95 rows=6842 width=4) (actual time=0.084..25.751 > rows=6847 loops=1) the rows estimates are accurate, so it is not a question of statistics anymore. first make sure effective_cache_size is correctly set, and then if that is not enough, you might try to lower random_page_cost a bit gnari