Received: from localhost (mx1.hub.org [200.46.208.251]) by postgresql.org (Postfix) with ESMTP id 0443A9FA1A7 for ; Wed, 18 Oct 2006 18:19:42 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.208.251]) (amavisd-new, port 10024) with ESMTP id 55680-04 for ; Wed, 18 Oct 2006 18:19:35 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey- Received: from achille.dalibo.net (achille.dalibo.net [212.85.153.230]) by postgresql.org (Postfix) with ESMTP id 69D359FB1E6 for ; Wed, 18 Oct 2006 18:19:35 -0300 (ADT) Received: from localhost (localhost.localdomain [127.0.0.1]) by achille.dalibo.net (Postfix) with ESMTP id 044B415F60; Wed, 18 Oct 2006 23:19:34 +0200 (CEST) Received: from achille.dalibo.net ([127.0.0.1]) by localhost (achille [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 19292-06; Wed, 18 Oct 2006 23:19:33 +0200 (CEST) Received: from [192.168.2.101] (unknown [84.5.55.48]) by achille.dalibo.net (Postfix) with ESMTP id 4674B15F5E; Wed, 18 Oct 2006 23:19:33 +0200 (CEST) From: Dimitri Fontaine Organization: dalibo To: pgsql-performance@postgresql.org Subject: Re: Postgresql 8.1.4 - performance issues for select on view using max Date: Wed, 18 Oct 2006 23:19:39 +0200 User-Agent: KMail/1.9.5 Cc: Ioana Danes References: <20061018210201.56435.qmail@web55907.mail.re3.yahoo.com> In-Reply-To: <20061018210201.56435.qmail@web55907.mail.re3.yahoo.com> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart1472774.2M63VviphR"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit Message-Id: <200610182319.41920.dim@dalibo.com> X-Virus-Scanned: by amavisd-new-20030616-p10 (Debian) at dalibo.com X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0 tagged_above=0 required=5 tests= X-Spam-Level: X-Archive-Number: 200610/379 X-Sequence-Number: 21508 --nextPart1472774.2M63VviphR Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Le mercredi 18 octobre 2006 23:02, Ioana Danes a =E9crit=A0: > I tried the partitioning scenario but I've got into > the same problem. The max function is not using the > indexes on the two partitioned tables... > > Any other thoughts? Did you make sure your test included table inheritance? I'm not sure the planner benefits from constraint_exclusion without selecti= ng=20 the empty parent table (instead of your own union based view). =2D-=20 Dimitri Fontaine http://www.dalibo.com/ --nextPart1472774.2M63VviphR Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.5 (GNU/Linux) iD8DBQBFNpptl4JX7QVNfwQRAlwcAJ0SYdpF/6zgf/v3Y9FvD24STC+uEgCeK89+ KbTY+Igl2Lw0dJkAl1ho6xY= =BcwF -----END PGP SIGNATURE----- --nextPart1472774.2M63VviphR--