Re: [HACKERS] Hints (Was: Index Tuning Features)

2006-10-13 Thread Arturo Perez
In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] (Andrew Sullivan) wrote: > On Thu, Oct 12, 2006 at 08:34:45AM +0200, Florian Weimer wrote: > > > > Some statistics are very hard to gather from a sample, e.g. the number > > of distinct values in a column. > > I like the suggestion, though, tha

Re: [HACKERS] Hints WAS: Index Tuning Features

2006-10-13 Thread Zeugswetter Andreas ADI SD
> And, to give you a starting point: the discussion has morphed into: > "What manual ways can we come up with for the DBA to > influence the planner and fix planner "bugs" which won't have > the fragility of query-based hints ala Oracle?" I see a few downsides though: 1. it lacks a way to try

Re: [HACKERS] Hints WAS: Index Tuning Features

2006-10-12 Thread Greg Stark
Martijn van Oosterhout writes: > Which could then be used by the planner. Or more directly: > > CREATE HISTOGRAM FOR FUNCTION verify_pk_signature(documenent) > AS ( true = 99, false = 1 ); > > (Perhaps DECLARE is the better phrase?). Except that the distribution is a property of the values y

Re: [HACKERS] Hints WAS: Index Tuning Features

2006-10-12 Thread Josh Berkus
Mark, That is sort of the stopping block. None of us "know" what it should look like, but leaving the topic as "if you want it, go do the work and submit a patch." Isn't going to get it done. First we should decide if it is, in fact, something that ought to happen, then if that happens, we shou

Re: [HACKERS] Hints WAS: Index Tuning Features

2006-10-12 Thread Martijn van Oosterhout
On Thu, Oct 12, 2006 at 02:25:29PM +0100, Simon Riggs wrote: > The CREATE OPERATOR command already has a RESTRICT=res_proc clause which > provides the ability to attach selectivity functions onto an operator. > > So this is already possible if you turn radius_authenticate() into an > operator. The

Re: [HACKERS] Hints WAS: Index Tuning Features

2006-10-12 Thread Simon Riggs
On Thu, 2006-10-12 at 15:06 +0200, Martijn van Oosterhout wrote: > On Thu, Oct 12, 2006 at 08:50:04AM -0400, Greg Stark wrote: > > Not to say this isn't a good idea -- i think it's a great idea. But note > > that > > it doesn't solve some of the use cases of hints. Consider something like: > > >

Re: [HACKERS] Hints WAS: Index Tuning Features

2006-10-12 Thread Ron Mayer
Mark Woodward wrote: > > Exactly. IMHO, it is a frustrating environment. PostgreSQL is a great > system, and while I completely respect the individuals involved, I think > the "management" for lack of a better term, is difficult. 'course you're welcome to fork the project as well if your style an

Re: [HACKERS] Hints WAS: Index Tuning Features

2006-10-12 Thread Martijn van Oosterhout
On Thu, Oct 12, 2006 at 08:50:04AM -0400, Greg Stark wrote: > Not to say this isn't a good idea -- i think it's a great idea. But note that > it doesn't solve some of the use cases of hints. Consider something like: > > WHERE NOT radius_authenticate(suspected_hacker) > > or > > WHERE NOT ver

Re: [HACKERS] Hints WAS: Index Tuning Features

2006-10-12 Thread Greg Stark
Simon Riggs <[EMAIL PROTECTED]> writes: > The *right* place, IMHO, for planner information is to decorate the > tables, columns and relationships so that *every* SQL statement can pick > that up. If the world changes, you make one change and all your SQL > benefits. As the analyzers improve, you

Re: [HACKERS] Hints WAS: Index Tuning Features

2006-10-12 Thread Mark Woodward
> Clinging to sanity, [EMAIL PROTECTED] ("Mark Woodward") mumbled into > her beard: >> What is the point of writing a proposal if there is a threat of >> "will be rejected" if one of the people who would do the rejection >> doesn't at least outline what would be acceptable? > > If your proposal is

Re: [HACKERS] Hints WAS: Index Tuning Features

2006-10-12 Thread Simon Riggs
On Wed, 2006-10-11 at 19:18 -0400, Mark Woodward wrote: > > > > Since you're the one who wants hints, that's kind of up to you to define. > > Write a specification and make a proposal. > > > > What is the point of writing a proposal if there is a threat of "will be > rejected" if one of the people

Re: [HACKERS] Hints WAS: Index Tuning Features

2006-10-11 Thread Tom Lane
"Mark Woodward" <[EMAIL PROTECTED]> writes: > What is the point of writing a proposal if there is a threat of "will be > rejected" if one of the people who would do the rejection doesn't at least > outline what would be acceptable? FWIW, I said some things about what I'd consider a good design in

Re: [HACKERS] Hints WAS: Index Tuning Features

2006-10-11 Thread Christopher Browne
Clinging to sanity, [EMAIL PROTECTED] ("Mark Woodward") mumbled into her beard: >> Mark, >> >> First off, I'm going to request that you (and other people) stop >> hijacking Simon's thread on hypothetical indexes. Hijacking >> threads is an effective way to get your ideas rejected out of hand, >> j

Re: [HACKERS] Hints WAS: Index Tuning Features

2006-10-11 Thread Joshua D. Drake
Mark Woodward wrote: Since you're the one who wants hints, that's kind of up to you to define. Write a specification and make a proposal. >>> What is the point of writing a proposal if there is a threat of "will be >>> rejected" if one of the people who would do the rejection do

Re: [HACKERS] Hints WAS: Index Tuning Features

2006-10-11 Thread Mark Woodward
>>> >>> Since you're the one who wants hints, that's kind of up to you to >>> define. >>> Write a specification and make a proposal. >>> >> >> What is the point of writing a proposal if there is a threat of "will be >> rejected" if one of the people who would do the rejection doesn't at >> least >>

Re: [HACKERS] Hints WAS: Index Tuning Features

2006-10-11 Thread Joshua D. Drake
>> >> Since you're the one who wants hints, that's kind of up to you to define. >> Write a specification and make a proposal. >> > > What is the point of writing a proposal if there is a threat of "will be > rejected" if one of the people who would do the rejection doesn't at least > outline what

Re: [HACKERS] Hints WAS: Index Tuning Features

2006-10-11 Thread Mark Woodward
> Mark, > > First off, I'm going to request that you (and other people) stop hijacking > Simon's thread on hypothetical indexes. Hijacking threads is an > effective way to get your ideas rejected out of hand, just because the > people whose thread you hijacked are angry with you. > > So please ob

Re: [HACKERS] Hints WAS: Index Tuning Features

2006-10-11 Thread Josh Berkus
Mark, First off, I'm going to request that you (and other people) stop hijacking Simon's thread on hypothetical indexes. Hijacking threads is an effective way to get your ideas rejected out of hand, just because the people whose thread you hijacked are angry with you. So please observe the