Greg Whalin wrote:
We have noticed this as well and it is really pretty shoddy. It seems
that when using IN( SELECT ), they treat it as ANY() which does a
full table scan.
Only way we have found to get fast performance out of subqueries is to
use the derived table format and join with the
We have noticed this as well and it is really pretty shoddy. It seems
that when using IN( SELECT ), they treat it as ANY() which does a
full table scan.
Only way we have found to get fast performance out of subqueries is to
use the derived table format and join with the derived table. But
http://www.peerfear.org/rss/permalink/2005/04/02/BrokenMySQLSubqueries
Whats up with this?
As far as I can tell MySQL subqueries in 4.1.x releases are totally
broken with IN clauses The major reason is that they don't use *ANY*
indexes and resort to full table scans.
Lets take two queries:
m