X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 273E3D1E971 for ; Thu, 15 Apr 2004 21:18:46 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 66774-10 for ; Thu, 15 Apr 2004 21:18:51 -0300 (ADT) Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by svr1.postgresql.org (Postfix) with ESMTP id D50FFD1B8B7 for ; Thu, 15 Apr 2004 21:18:43 -0300 (ADT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.12.11/8.12.11) with ESMTP id i3G0InlS022643; Thu, 15 Apr 2004 20:18:49 -0400 (EDT) To: Manfred Koizar Cc: Robert Treat , pgsql-performance@postgresql.org Subject: Re: query slows down with more accurate stats In-reply-to: References: <1081879359.25537.526.camel@camel> <25556.1081883922@sss.pgh.pa.us> Comments: In-reply-to Manfred Koizar message dated "Fri, 16 Apr 2004 01:32:53 +0200" Date: Thu, 15 Apr 2004 20:18:49 -0400 Message-ID: <22642.1082074729@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200404/198 X-Sequence-Number: 6498 Manfred Koizar writes: > My biggest concern at the moment is that the new sampling method > violates the contract of returning each possible sample with he same > probability: getting several tuples from the same page is more likely > than with the old method. Hm, are you sure? I recall objecting to your original proposal because I thought that would happen, but after further thought it seemed not. Also, I'm not at all sure that the old method satisfies that constraint completely in the presence of nonuniform numbers of tuples per page, so we'd not necessarily be going backwards anyhow ... regards, tom lane