Received: from localhost (unknown [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id DE6429FC358 for ; Thu, 1 Nov 2007 12:36:19 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-maia, port 10024) with ESMTP id 38884-03 for ; Thu, 1 Nov 2007 12:36:00 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by postgresql.org (Postfix) with ESMTP id CB0F79FC2CA for ; Thu, 1 Nov 2007 12:35:15 -0300 (ADT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.1/8.14.1) with ESMTP id lA1FYgLf006025; Thu, 1 Nov 2007 11:34:43 -0400 (EDT) To: Palle Girgensohn cc: pgsql-performance@postgresql.org Subject: Re: select max(field) from table much faster with a group by clause? In-reply-to: <16563C7D831BD7B32DFBDDEC@rambutan.pingpong.net> References: <4305.1193924619@sss.pgh.pa.us> <5504.1193929617@sss.pgh.pa.us> <16563C7D831BD7B32DFBDDEC@rambutan.pingpong.net> Comments: In-reply-to Palle Girgensohn message dated "Thu, 01 Nov 2007 16:25:08 +0100" Date: Thu, 01 Nov 2007 11:34:42 -0400 Message-ID: <6024.1193931282@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200711/19 X-Sequence-Number: 27434 Palle Girgensohn writes: > --On torsdag, november 01, 2007 11.06.57 -0400 Tom Lane > wrote: >> Um, you did re-ANALYZE the table after changing the setting? > alter table login alter userid SET statistics 1000; > vacuum analyze login; Hm, that's the approved procedure all right. But the plans didn't change at all? Not even the estimated number of rows? regards, tom lane