Skip navigation links

MySQL Forums :: Optimizer & Parser :: Explain the order of query


Advanced Search

Re: Explain the order of query
Posted by: Rick James ()
Date: March 19, 2012 10:38PM

If there are no subqueries or UNIONs, the tables listed in EXPLAIN are accessed in the order presented. First the execution will go into/through the first table (or its index). From there, it will reach into the next table ("Nested Loop Join"). Etc.

With subqueries, there is some jumping around to the <derived> subquery.

UNION show each of the SELECTs in the UNION, plus something like <UNION 2,3> to say that it is combining the results.

Does that answer you question? If not, provide a concrete example to discuss.

Options: ReplyQuote


Subject Views Written By Posted
Explain the order of query 1169 jongse park 03/19/2012 01:49AM
Re: Explain the order of query 543 Rick James 03/19/2012 10:38PM
Re: Explain the order of query 567 jongse park 03/21/2012 07:06PM
Re: Explain the order of query 478 Rick James 03/22/2012 06:01PM
Re: Explain the order of query 468 jongse park 03/22/2012 08:13PM
Re: Explain the order of query 473 Rick James 03/23/2012 07:57PM
Re: Explain the order of query 653 Jørgen Løland 03/28/2012 05:06AM


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.