Subquery optimizations map
You are viewing an old version of this article. View
the current version here.
Below is a map, that shows all kinds of subqueries allowed in the SQL language, and optimizer strategies availabe to handle them
- Uncolored areas represent different kinds of subqueries, for example:
- Subqueries that have form
x IN (SELECT ...)
- Subqueries that are in the
FROM
clause - .. and so forth
- Subqueries that have form
- The size of each uncolored area roughly corresponds to how important (i.e. frequently used) that kind of subquery is. For example,
x IN (SELECT ...)
are the most important, andEXISTS (SELECT ...)
are relatively unimportant. - Colored areas represent optimizations/execution strategies that are applied to handle various kinds of subqueries.
- The color of optimization indicates which version of MySQL/MariaDB it was available in (see legend below)
Links to pages about individual optimizations:
- Non-semi-join Materialization (including NULL-aware and partial matching)
See also
Comments
Comments loading...
Content reproduced on this site is the property of its respective owners,
and this content is not reviewed in advance by MariaDB. The views, information and opinions
expressed by this content do not necessarily represent those of MariaDB or any other party.