Commit 1a8486a8 authored by unknown's avatar unknown

MDEV-4345: fixed optimizer_selectivity_sampling_limit default value.

parent c44c9231
SET @start_global_value = @@global.optimizer_selectivity_sampling_limit;
SELECT @start_global_value;
@start_global_value
5000
100
SET @start_session_value = @@session.optimizer_selectivity_sampling_limit;
SELECT @start_session_value;
@start_session_value
5000
100
'#--------------------FN_DYNVARS_115_01-------------------------#'
SET @@global.optimizer_selectivity_sampling_limit = DEFAULT;
SELECT @@global.optimizer_selectivity_sampling_limit;
@@global.optimizer_selectivity_sampling_limit
5000
100
SET @@session.optimizer_selectivity_sampling_limit = DEFAULT;
SELECT @@session.optimizer_selectivity_sampling_limit;
@@session.optimizer_selectivity_sampling_limit
5000
100
'#--------------------FN_DYNVARS_115_02-------------------------#'
SET @@global.optimizer_selectivity_sampling_limit = DEFAULT;
SELECT @@global.optimizer_selectivity_sampling_limit = 5000;
@@global.optimizer_selectivity_sampling_limit = 5000
SELECT @@global.optimizer_selectivity_sampling_limit = 100;
@@global.optimizer_selectivity_sampling_limit = 100
1
SET @@session.optimizer_selectivity_sampling_limit = DEFAULT;
SELECT @@session.optimizer_selectivity_sampling_limit = 5000;
@@session.optimizer_selectivity_sampling_limit = 5000
SELECT @@session.optimizer_selectivity_sampling_limit = 100;
@@session.optimizer_selectivity_sampling_limit = 100
1
'#--------------------FN_DYNVARS_115_03-------------------------#'
SELECT @@global.optimizer_selectivity_sampling_limit;
@@global.optimizer_selectivity_sampling_limit
5000
100
SET @@global.optimizer_selectivity_sampling_limit = 9;
Warnings:
Warning 1292 Truncated incorrect optimizer_selectivity_sampling_l value: '9'
......@@ -63,7 +63,7 @@ SELECT @@global.optimizer_selectivity_sampling_limit;
'#--------------------FN_DYNVARS_115_04-------------------------#'
SELECT @@session.optimizer_selectivity_sampling_limit;
@@session.optimizer_selectivity_sampling_limit
5000
100
SET @@session.optimizer_selectivity_sampling_limit = 9;
Warnings:
Warning 1292 Truncated incorrect optimizer_selectivity_sampling_l value: '9'
......@@ -134,8 +134,8 @@ SELECT @@local.optimizer_selectivity_sampling_limit = @@session.optimizer_select
SET @@global.optimizer_selectivity_sampling_limit = @start_global_value;
SELECT @@global.optimizer_selectivity_sampling_limit;
@@global.optimizer_selectivity_sampling_limit
5000
100
SET @@session.optimizer_selectivity_sampling_limit = @start_session_value;
SELECT @@session.optimizer_selectivity_sampling_limit;
@@session.optimizer_selectivity_sampling_limit
5000
100
......@@ -34,10 +34,10 @@ SELECT @@session.optimizer_selectivity_sampling_limit;
#########################################################################
SET @@global.optimizer_selectivity_sampling_limit = DEFAULT;
SELECT @@global.optimizer_selectivity_sampling_limit = 5000;
SELECT @@global.optimizer_selectivity_sampling_limit = 100;
SET @@session.optimizer_selectivity_sampling_limit = DEFAULT;
SELECT @@session.optimizer_selectivity_sampling_limit = 5000;
SELECT @@session.optimizer_selectivity_sampling_limit = 100;
--echo '#--------------------FN_DYNVARS_115_03-------------------------#'
......
......@@ -1052,7 +1052,7 @@ void store_key_image_to_rec(Field *field, uchar *ptr, uint len);
extern String null_string;
/* check this number of rows (default value) */
#define SELECTIVITY_SAMPLING_LIMIT 5000
#define SELECTIVITY_SAMPLING_LIMIT 100
/* but no more then this part of table (10%) */
#define SELECTIVITY_SAMPLING_SHARE 0.10
/* do not check if we are going check less then this number of records */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment