diff options
author | Igor Babaev <igor@askmonty.org> | 2013-03-25 23:48:29 -0700 |
---|---|---|
committer | Igor Babaev <igor@askmonty.org> | 2013-03-25 23:48:29 -0700 |
commit | 1009832c13380365c03f77fcabd0fda470b73390 (patch) | |
tree | 73e123df951d60220a4cb0cac2ca19b2ebff7056 /mysql-test/t/statistics.test | |
parent | fc1c8ffdadfd14eb51969ecfde43e3204f10f6f8 (diff) | |
download | mariadb-git-1009832c13380365c03f77fcabd0fda470b73390.tar.gz |
Added histogams for table columns.
Diffstat (limited to 'mysql-test/t/statistics.test')
-rw-r--r-- | mysql-test/t/statistics.test | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/mysql-test/t/statistics.test b/mysql-test/t/statistics.test index 4f2d0510c11..65412d849ed 100644 --- a/mysql-test/t/statistics.test +++ b/mysql-test/t/statistics.test @@ -165,6 +165,23 @@ SELECT WHERE t1.e IS NOT NULL AND t1.b IS NOT NULL AND t1.d IS NOT NULL) AS 'ARITY 3'; + +DELETE FROM mysql.column_stats; + +set histogram_size=4; +ANALYZE TABLE t1; + +SELECT db_name, table_name, column_name, + min_value, max_value, + nulls_ratio, avg_frequency, + hist_size, HEX(histogram) + FROM mysql.column_stats; + +DELETE FROM mysql.column_stats; +set histogram_size= 0; +ANALYZE TABLE t1; + + CREATE TABLE t3 ( a int NOT NULL PRIMARY KEY, b varchar(32), |