1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

Merge branch '10.2' into 10.3

This commit is contained in:
Sergei Golubchik
2021-02-22 21:25:16 +01:00
62 changed files with 1416 additions and 1296 deletions

View File

@ -212,6 +212,17 @@ public:
bool is_available() { return get_size() > 0 && get_values(); }
/*
This function checks that histograms should be usable only when
1) the level of optimizer_use_condition_selectivity > 3
2) histograms have been collected
*/
bool is_usable(THD *thd)
{
return thd->variables.optimizer_use_condition_selectivity > 3 &&
is_available();
}
void set_value(uint i, double val)
{
switch (type) {