Re: An Idea for planner hints - Mailing list pgsql-hackers

From Tom Lane
Subject Re: An Idea for planner hints
Date
Msg-id 28513.1155151619@sss.pgh.pa.us
Whole thread Raw
In response to Re: An Idea for planner hints  ("Jim C. Nasby" <jnasby@pervasive.com>)
Responses Re: An Idea for planner hints
List pgsql-hackers
"Jim C. Nasby" <jnasby@pervasive.com> writes:
> On Wed, Aug 09, 2006 at 02:02:10PM +0200, Martijn van Oosterhout wrote:
>> Perhaps the way to go would be to allow users to declare columns often
>> used together and have ANALYSE collect information on correlation which
>> can be used later...

> One thing that would help tremendously would be to collect stats on
> multi-column indexes. That would probably hit a good chunk of our
> problem areas.

But it would specifically fail to cover join situations.  I kinda like
Martijn's thought of allowing users to specify combinations of columns
to collect correlation stats about.

(Not sure how we'd implement that, seeing that ANALYZE currently works
on one table at a time, but it's probably doable --- and it'd fix the
fundamental problem for correlation statistics, which is how not to try
to collect stats about an exponential number of combinations ...)
        regards, tom lane


pgsql-hackers by date:

Previous
From: "Jim C. Nasby"
Date:
Subject: Re: An Idea for planner hints
Next
From: Tom Lane
Date:
Subject: Re: 8.2 features status