@@optimizer_switch is a server variable that one can use to enable/disable specific optimizations. For generic syntax, see Switchable Optimizations in MySQL Manual.
Below is a list of all @@optimizer_switch flags available in MariaDB 5.3:
| Flag and default setting | Supported in MariaDB since | Supported in MySQL since |
|---|---|---|
derived_merge=on | MariaDB 5.3 | - |
derived_with_keys=on | MariaDB 5.3 | - |
index_condition_pushdown=on | MariaDB 5.3 | MySQL 5.6 |
index_merge=on | MariaDB 5.1 | MySQL 5.1.x |
index_merge_union=on | MariaDB 5.1 | MySQL 5.1.x |
index_merge_sort_union=on | MariaDB 5.1 | MySQL 5.1.x |
index_merge_intersection=on | MariaDB 5.1 | MySQL 5.1.x |
index_merge_sort_intersection=off | MariaDB 5.3 | - |
mrr=off | MariaDB 5.3 | MySQL 5.6 |
mrr_cost_based=off | MariaDB 5.3 | MySQL 5.6 |
mrr_sort_keys=off | MariaDB 5.3 | - |
materialization=on | MariaDB 5.3 | - |
subquery_cache=on | MariaDB 5.3 | - |
semijoin=on | MariaDB 5.3 | - |
firstmatch=on | MariaDB 5.3 | - |
loosescan=on | MariaDB 5.3 | - |
in_to_exists=on | MariaDB 5.3 | - |
partial_match_rowid_merge=on | MariaDB 5.3 | - |
partial_match_table_scan=on | MariaDB 5.3 | - |
join_cache_bka=on | MariaDB 5.3 | - |
join_cache_hashed=on | MariaDB 5.3 | - |
join_cache_incremental=on | MariaDB 5.3 | - |
outer_join_with_cache=on | MariaDB 5.3 | - |
semijoin_with_cache=on | MariaDB 5.3 | - |
optimize_join_buffer_size=off | MariaDB 5.3 | - |
table_elimination=on | MariaDB 5.1 | - |
The following optimizer_switch flags are present in MySQL but not in MariaDB:
| Flag and default setting | Supported in MariaDB since | Supported in MySQL since |
|---|---|---|
engine_condition_pushdown=on | - | MySQL 5.1 |
Note that the feature behind this flag, Table Condition Pushdown, is only used by NDB Cluster.
See Also:
Comments
Comments loading...