List:General Discussion« Previous MessageNext Message »
From:<nospam Date:July 9 2003 4:18pm
Subject:order of table joins or where clauses relevant?
View as plain text  
As we're on this topic in another thread right now:

Say I have a SELECT query from more than one table and with some conditions, does it
matter in what order I enter the tables in the FROM clause and in what order the WHERE
conditions appear in my query? Or does it make any difference if I use WHERE or HAVING?
(I see that MS Access likes those HAVINGs...)

Of course my tables contain (maybe very much) more than some 100 records and are
well-indexed, I believe.... but that's not my question for now.

I guess, the MySQL optimizer reads the table and column names in the specified order and
tries to process them the same way, right? Or it joins the tables in my given order...
And when are the resulting records reduced by matching against my conditions? Maybe
someone can tell me a little bit about performance gains just by doing some 'manual query
optimization' :)

Yves Goergen
www.unclassified.de

Thread
Access deniedAsterix11 Mar
  • Re: Access deniedChristian Mack11 Mar
  • Re: Can mysql handle this load?nospam9 Jul
  • RE: Can mysql handle this load?Andy Eastham9 Jul
  • Re: Can mysql handle this load?Krasimir_Slaveykov10 Jul
  • Left Join - Revistedvernon10 Jul
RE: Can mysql handle this load?Mike Hillyer9 Jul
RE: Can mysql handle this load?Rudy Metzger9 Jul
RE: Can mysql handle this load?Rudy Metzger9 Jul
RE: Can mysql handle this load?Rudy Metzger9 Jul
RE: order of table joins or where clauses relevant?Rudy Metzger10 Jul
RE: Left Join - RevistedRudy Metzger11 Jul
RE: Can mysql handle this load?Rudy Metzger14 Jul