SET @start_global_value = @@global.histogram_type;
SELECT @start_global_value;
@start_global_value
JSON_HB
SET @start_session_value = @@session.histogram_type;
SELECT @start_session_value;
@start_session_value
JSON_HB
SET @@global.histogram_type = 1;
SET @@global.histogram_type = DEFAULT;
SELECT @@global.histogram_type;
@@global.histogram_type
JSON_HB
SET @@global.histogram_type = 0;
SELECT @@global.histogram_type;
@@global.histogram_type
SINGLE_PREC_HB
SET @@global.histogram_type = 1;
SELECT @@global.histogram_type;
@@global.histogram_type
DOUBLE_PREC_HB
SET @@global.histogram_type = SINGLE_PREC_HB;
SELECT @@global.histogram_type;
@@global.histogram_type
SINGLE_PREC_HB
SET @@global.histogram_type = DOUBLE_PREC_HB;
SELECT @@global.histogram_type;
@@global.histogram_type
DOUBLE_PREC_HB
SET @@session.histogram_type = 0;
SELECT @@session.histogram_type;
@@session.histogram_type
SINGLE_PREC_HB
SET @@session.histogram_type = 1;
SELECT @@session.histogram_type;
@@session.histogram_type
DOUBLE_PREC_HB
SET @@session.histogram_type = SINGLE_PREC_HB;
SELECT @@session.histogram_type;
@@session.histogram_type
SINGLE_PREC_HB
SET @@session.histogram_type = DOUBLE_PREC_HB;
SELECT @@session.histogram_type;
@@session.histogram_type
DOUBLE_PREC_HB
set sql_mode=TRADITIONAL;
SET @@global.histogram_type = 10;
ERROR 42000: Variable 'histogram_type' can't be set to the value of '10'
SET @@global.histogram_type = -1024;
ERROR 42000: Variable 'histogram_type' can't be set to the value of '-1024'
SET @@global.histogram_type = 2.4;
ERROR 42000: Incorrect argument type to variable 'histogram_type'
SET @@global.histogram_type = OFF;
ERROR 42000: Variable 'histogram_type' can't be set to the value of 'OFF'
SET @@session.histogram_type = 10;
ERROR 42000: Variable 'histogram_type' can't be set to the value of '10'
SET @@session.histogram_type = -2;
ERROR 42000: Variable 'histogram_type' can't be set to the value of '-2'
SET @@session.histogram_type = 1.2;
ERROR 42000: Incorrect argument type to variable 'histogram_type'
SET @@session.histogram_type = ON;
ERROR 42000: Variable 'histogram_type' can't be set to the value of 'ON'
SELECT * FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES 
WHERE VARIABLE_NAME='histogram_type';
VARIABLE_NAME	VARIABLE_VALUE
HISTOGRAM_TYPE	DOUBLE_PREC_HB
SELECT * FROM INFORMATION_SCHEMA.SESSION_VARIABLES 
WHERE VARIABLE_NAME='histogram_type';
VARIABLE_NAME	VARIABLE_VALUE
HISTOGRAM_TYPE	DOUBLE_PREC_HB
SET @@global.histogram_type = @start_global_value;
SELECT @@global.histogram_type;
@@global.histogram_type
JSON_HB
SET @@session.histogram_type = @start_session_value;
SELECT @@session.histogram_type;
@@session.histogram_type
JSON_HB
set sql_mode='';
