Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id B5407634038 for ; Tue, 13 Jul 2010 01:01:01 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.29]) (amavisd-maia, port 10024) with ESMTP id 58171-01-5 for ; Tue, 13 Jul 2010 04:00:54 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from spinlock.commandprompt.com (host-215.commandprompt.net [207.173.203.215]) by mail.postgresql.org (Postfix) with ESMTP id 195EB63400D for ; Tue, 13 Jul 2010 01:00:54 -0300 (ADT) Received: from localhost (localhost [127.0.0.1]) by spinlock.commandprompt.com (Postfix) with ESMTP id 75E82348037; Mon, 12 Jul 2010 21:00:53 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at commandprompt.com Received: from spinlock.commandprompt.com ([127.0.0.1]) by localhost (spinlock.commandprompt.com.commandprompt.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id iovpEipl8o-u; Mon, 12 Jul 2010 21:00:51 -0700 (PDT) Received: from [75.142.153.107] (unknown [75.142.153.107]) by spinlock.commandprompt.com (Postfix) with ESMTPSA id 1932C348002; Mon, 12 Jul 2010 21:00:51 -0700 (PDT) Subject: Re: partition queries hitting all partitions even though check key is specified From: "Joshua D. Drake" Reply-To: jd@commandprompt.com To: Josh Berkus Cc: Kevin Kempter , pgsql-performance@postgresql.org In-Reply-To: <4C3BD6F4.4070802@agliodbs.com> References: <200909020852.30405.kevink@consistentstate.com> <200909020905.18688.kevink@consistentstate.com> <4C3BD6F4.4070802@agliodbs.com> Content-Type: text/plain; charset="UTF-8" Organization: Command Prompt, Inc. Date: Mon, 12 Jul 2010 21:00:48 -0700 Message-ID: <1278993648.22491.7.camel@jd-desktop.unknown.charter.com> Mime-Version: 1.0 X-Mailer: Evolution 2.28.3 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: 201007/203 X-Sequence-Number: 39592 On Mon, 2010-07-12 at 22:01 -0500, Josh Berkus wrote: > On 9/2/09 10:05 AM, Kevin Kempter wrote: > > On Wednesday 02 September 2009 09:02:27 Scott Marlowe wrote: > >> On Wed, Sep 2, 2009 at 8:52 AM, Kevin Kempter > > wrote: > >>> Hi all; > >>> > >>> I cant figure out why we're scanning all of our partitions. > > I don't think extract() is immutable, which would pretty much invalidate > your check constraints as far as CE is concerned. Correct. Joshua D. Drake -- PostgreSQL.org Major Contributor Command Prompt, Inc: http://www.commandprompt.com/ - 509.416.6579 Consulting, Training, Support, Custom Development, Engineering