Re: Possible bug in self-join order optimization

2001-10-22 Thread Sinisa Milivojevic
On Sat, 20 Oct 2001 12:48:36 -0500 Eric <[EMAIL PROTECTED]> wrote: I wouldn't be opposed to implementing this as a part of the join optimizer in MySQL, in fact, I've been reading through it for a few days now... However, it seems like it would be a large project as the join optimizer does not t

Re: Possible bug in self-join order optimization

2001-10-20 Thread Eric
Well, I would definitely have to do the count for each query; not because my table sizes are changing (although they are at a fairly rapid rate), but because the number of rows I want to select is vastly different between queries. This is actually a self-join (refer to first emails from me to thi

Re: Possible bug in self-join order optimization

2001-10-20 Thread Sinisa Milivojevic
Eric writes: > I have no problem using STRAIGHT_JOIN, etc. My problem is really just > figuring out the optimal join order. Is doing a "SELECT COUNT" on > each of the tables I'm going to join the way to do it? Isn't there > potential for the count to take as long as the full query processing >

Re: Possible bug in self-join order optimization

2001-10-20 Thread Eric
The information I require is the number of rows that will come from a SELECT which places a certain range restriction on an unindexed attribute...and I need this to not take much time relative to actually executing the query (constant time would be best). eric. On Sat, Oct 20, 2001 at 03:06:58PM

Re: Possible bug in self-join order optimization

2001-10-20 Thread Eric
I have no problem using STRAIGHT_JOIN, etc. My problem is really just figuring out the optimal join order. Is doing a "SELECT COUNT" on each of the tables I'm going to join the way to do it? Isn't there potential for the count to take as long as the full query processing would take (especially

Re: Possible bug in self-join order optimization

2001-10-20 Thread Sinisa Milivojevic
Eric writes: > Well, answering my own email, what I thought was a bug is not one at > all. I was mistaken in thinking that MySQL paid any attention to the > WHERE conditions when optimizing the join order beyond determining > which keys are used for the join, correct? > > This is really terrib

Re: Possible bug in self-join order optimization

2001-10-20 Thread Sinisa Milivojevic
On Fri, 19 Oct 2001 13:03:02 -0500 Eric <[EMAIL PROTECTED]> wrote: > Well, answering my own email, what I thought was a bug is not one at > all. I was mistaken in thinking that MySQL paid any attention to the > WHERE conditions when optimizing the join order beyond determining > which keys are

Re: Possible bug in self-join order optimization

2001-10-19 Thread Eric
Well, answering my own email, what I thought was a bug is not one at all. I was mistaken in thinking that MySQL paid any attention to the WHERE conditions when optimizing the join order beyond determining which keys are used for the join, correct? This is really terrible for queries like mine

Possible bug in self-join order optimization

2001-10-18 Thread Eric
I am sending this again as I am desperate for some help and believe this to be a signifigant bug if it actually is one...which it seems to be. See below for examples. What is quite puzzling is MySQL's estimation of the number of rows from each of the self-joins. The conditions on alias queryTab