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 DAE743A42B9 for ; Wed, 17 Nov 2004 08:19:20 +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 72961-02 for ; Wed, 17 Nov 2004 08:19:10 +0000 (GMT) Received: from mail63.csoft.net (leary3.csoft.net [63.111.22.74]) by svr1.postgresql.org (Postfix) with SMTP id B14723A41EA for ; Wed, 17 Nov 2004 08:19:08 +0000 (GMT) Received: (qmail 20076 invoked by uid 1112); 17 Nov 2004 08:19:39 -0000 Date: Wed, 17 Nov 2004 03:19:39 -0500 (EST) From: Kris Jurka X-X-Sender: books@leary.csoft.net To: Simon Riggs Cc: pgsql-performance@postgresql.org Subject: Re: mis-estimation on data-warehouse aggregate creation In-Reply-To: <1100640596.4113.5680.camel@localhost.localdomain> Message-ID: References: <1100640596.4113.5680.camel@localhost.localdomain> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200411/245 X-Sequence-Number: 9199 On Tue, 16 Nov 2004, Simon Riggs wrote: > The join condition has so many ANDed predicates that we assume that this > will reduce the selectivity considerably. It does not, and so you pay > the cost dearly later on. > Yes, that makes a lot of sense. Without some incredibly good cross-column statistics there is no way it could expect all of the rows to match. Thanks for the analysis. Kris Jurka