MySQL Forums
Forum List  »  Performance

Re: Mysql must be braindead!
Posted by: KimSeong Loh
Date: November 13, 2005 07:45PM

Your query is considered complex.

For every row found in cdr table which satisfy the where condition date='03/11/2005' and duration>0,
it will have to execute select rate from agentcost 1 time, and for each row in agentcost, it will have to execute select rate1 from agentprofile,agent 1 time.

Consider how many select does this need to execute.

Looking at the output of EXPLAIN, it is estimated that mysql needs to examine upto 78254 * 767 * 25 rows, that upto 1.5 billion rows to be examined, of course the using where may reduce the number depending to the data values.

Options: ReplyQuote


Subject
Views
Written By
Posted
1605
November 12, 2005 11:58AM
Re: Mysql must be braindead!
1118
November 13, 2005 07:45PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.