Skip site navigation (1) Skip section navigation (2)

Re: Group-count estimation statistics

From: Manfred Koizar <mkoi-pg(at)aon(dot)at>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Group-count estimation statistics
Date: 2005-02-01 15:29:30
Message-ID: vh6vv0ds3b61jseji2c3271di2iu203p8p@email.aon.at (view raw or flat)
Thread:
Lists: pgsql-hackers
On Mon, 31 Jan 2005 14:40:08 -0500, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>Manfred Koizar <mkoi-pg(at)aon(dot)at> writes:
>> That's not what I meant.  I tried to say that if we have a GROUP BY
>> several columns and one of these columns alone has more than N/10
>> distinct values, there's no way to get less than that many groups.
>
>Oh, I see, you want a "max" calculation in there too.  Seems reasonable.
>Any objections?

Yes.  :-(  What I said is only true in the absence of any WHERE clause
(or join).  Otherwise the same cross-column correlation issues you tried
to work around with the N/10 clamping might come back through the
backdoor.  I'm not sure whether coding for such a narrow use case is
worth the trouble.  Forget my idea.

Servus
 Manfred

In response to

Responses

pgsql-hackers by date

Next:From: Tom LaneDate: 2005-02-01 15:37:30
Subject: Re: Our getopt_long() doesn't do abbreviations or NLS
Previous:From: Marc G. FournierDate: 2005-02-01 15:28:08
Subject: Re: 7.2.7 -> 8.0.1 Bundles Ready ...

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group