mirror of
https://github.com/MariaDB/server.git
synced 2025-01-24 15:54:37 +01:00
4b24105df8
When this flag is 'off' the size of the used join buffer is taken directly from the system variable 'join_buffer_size'. When this flag is 'on' then the size of the buffer depends on the estimated number of rows in the partial join whose records are to be stored in the buffer. By default this flag is set 'on'.
102 lines
11 KiB
Text
102 lines
11 KiB
Text
#
|
|
# Generic @@optimizer_switch tests
|
|
#
|
|
#
|
|
select @@optimizer_switch;
|
|
@@optimizer_switch
|
|
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=on,materialization=on,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|
|
set optimizer_switch='index_merge=off,index_merge_union=off';
|
|
select @@optimizer_switch;
|
|
@@optimizer_switch
|
|
index_merge=off,index_merge_union=off,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=on,materialization=on,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|
|
set optimizer_switch='index_merge_union=on';
|
|
select @@optimizer_switch;
|
|
@@optimizer_switch
|
|
index_merge=off,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=on,materialization=on,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|
|
set optimizer_switch='default,index_merge_sort_union=off';
|
|
select @@optimizer_switch;
|
|
@@optimizer_switch
|
|
index_merge=on,index_merge_union=on,index_merge_sort_union=off,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=on,materialization=on,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|
|
set optimizer_switch=4;
|
|
ERROR 42000: Variable 'optimizer_switch' can't be set to the value of '4'
|
|
set optimizer_switch=NULL;
|
|
ERROR 42000: Variable 'optimizer_switch' can't be set to the value of 'NULL'
|
|
set optimizer_switch='default,index_merge';
|
|
ERROR 42000: Variable 'optimizer_switch' can't be set to the value of 'index_merge'
|
|
set optimizer_switch='index_merge=index_merge';
|
|
ERROR 42000: Variable 'optimizer_switch' can't be set to the value of 'index_merge=index_merge'
|
|
set optimizer_switch='index_merge=on,but...';
|
|
ERROR 42000: Variable 'optimizer_switch' can't be set to the value of 'but...'
|
|
set optimizer_switch='index_merge=';
|
|
ERROR 42000: Variable 'optimizer_switch' can't be set to the value of 'index_merge='
|
|
set optimizer_switch='index_merge';
|
|
ERROR 42000: Variable 'optimizer_switch' can't be set to the value of 'index_merge'
|
|
set optimizer_switch='on';
|
|
ERROR 42000: Variable 'optimizer_switch' can't be set to the value of 'on'
|
|
set optimizer_switch='index_merge=on,index_merge=off';
|
|
ERROR 42000: Variable 'optimizer_switch' can't be set to the value of 'index_merge=off'
|
|
set optimizer_switch='index_merge_union=on,index_merge_union=default';
|
|
ERROR 42000: Variable 'optimizer_switch' can't be set to the value of 'index_merge_union=default'
|
|
set optimizer_switch='default,index_merge=on,index_merge=off,default';
|
|
ERROR 42000: Variable 'optimizer_switch' can't be set to the value of 'index_merge=off,default'
|
|
set optimizer_switch=default;
|
|
set optimizer_switch='index_merge=off,index_merge_union=off,default';
|
|
select @@optimizer_switch;
|
|
@@optimizer_switch
|
|
index_merge=off,index_merge_union=off,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=on,materialization=on,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|
|
set optimizer_switch=default;
|
|
select @@global.optimizer_switch;
|
|
@@global.optimizer_switch
|
|
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=on,materialization=on,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|
|
set @@global.optimizer_switch=default;
|
|
select @@global.optimizer_switch;
|
|
@@global.optimizer_switch
|
|
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=on,materialization=on,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|
|
#
|
|
# Check index_merge's @@optimizer_switch flags
|
|
#
|
|
select @@optimizer_switch;
|
|
@@optimizer_switch
|
|
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=on,materialization=on,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|
|
|
|
BUG#37120 optimizer_switch allowable values not according to specification
|
|
|
|
select @@optimizer_switch;
|
|
@@optimizer_switch
|
|
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=on,materialization=on,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|
|
set optimizer_switch='default,materialization=off';
|
|
select @@optimizer_switch;
|
|
@@optimizer_switch
|
|
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=on,materialization=off,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|
|
set optimizer_switch='default,semijoin=off';
|
|
select @@optimizer_switch;
|
|
@@optimizer_switch
|
|
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=on,materialization=on,semijoin=off,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|
|
set optimizer_switch='default,loosescan=off';
|
|
select @@optimizer_switch;
|
|
@@optimizer_switch
|
|
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=off,materialization=on,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|
|
set optimizer_switch='default,semijoin=off,materialization=off';
|
|
select @@optimizer_switch;
|
|
@@optimizer_switch
|
|
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=on,materialization=off,semijoin=off,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|
|
set optimizer_switch='default,materialization=off,semijoin=off';
|
|
select @@optimizer_switch;
|
|
@@optimizer_switch
|
|
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=on,materialization=off,semijoin=off,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|
|
set optimizer_switch='default,semijoin=off,materialization=off,loosescan=off';
|
|
select @@optimizer_switch;
|
|
@@optimizer_switch
|
|
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=off,materialization=off,semijoin=off,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|
|
set optimizer_switch='default,semijoin=off,loosescan=off';
|
|
select @@optimizer_switch;
|
|
@@optimizer_switch
|
|
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=off,materialization=on,semijoin=off,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|
|
set optimizer_switch='default,materialization=off,loosescan=off';
|
|
select @@optimizer_switch;
|
|
@@optimizer_switch
|
|
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=off,materialization=off,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|
|
set optimizer_switch=default;
|
|
select @@optimizer_switch;
|
|
@@optimizer_switch
|
|
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,firstmatch=on,loosescan=on,materialization=on,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr_sort_keys=on,outer_join_with_cache=off,semijoin_with_cache=off,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on
|