diff options
author | Jimmy Yang <jimmy.yang@oracle.com> | 2011-01-14 09:02:28 -0800 |
---|---|---|
committer | Jimmy Yang <jimmy.yang@oracle.com> | 2011-01-14 09:02:28 -0800 |
commit | 9cd4d4984025857782e12e53d32cea5e4b7684e5 (patch) | |
tree | 91674b9ab3c48997806024be85f5a431ad47574b /storage/innobase/include/dict0mem.h | |
parent | 634fe860562f7249c55a0f946a1fb50972b9f9ff (diff) | |
download | mariadb-git-9cd4d4984025857782e12e53d32cea5e4b7684e5.tar.gz |
Fix Bug#30423 "InnoDBs treatment of NULL in index stats causes bad
"rows examined" estimates". This change implements "innodb_stats_method"
with options of "nulls_equal", "nulls_unequal" and "null_ignored".
rb://553 approved by Marko
Diffstat (limited to 'storage/innobase/include/dict0mem.h')
-rw-r--r-- | storage/innobase/include/dict0mem.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/storage/innobase/include/dict0mem.h b/storage/innobase/include/dict0mem.h index 2f2a7441478..83dbf65ea41 100644 --- a/storage/innobase/include/dict0mem.h +++ b/storage/innobase/include/dict0mem.h @@ -222,6 +222,12 @@ struct dict_index_struct{ for this index, for each n-column prefix where n <= dict_get_n_unique(index); we periodically calculate new estimates */ + ib_longlong* stat_n_non_null_key_vals; + /* approximate number of non-null key values + for this index, for each column where + n < dict_get_n_unique(index); This + is used when innodb_stats_method is + "nulls_ignored". */ ulint stat_index_size; /* approximate index size in database pages */ ulint stat_n_leaf_pages; |