Commit ae9a4799 authored by Monty's avatar Monty Committed by Sergei Golubchik

MDEV-33938 Analyze table on sequences should be prohibited

parent 9e7e1f62
......@@ -17,7 +17,6 @@ Table Op Msg_type Msg_text
test.s1 optimize note The storage engine for the table doesn't support optimize
analyze table s1;
Table Op Msg_type Msg_text
test.s1 analyze status Engine-independent statistics collected
test.s1 analyze note The storage engine for the table doesn't support analyze
repair table s1;
Table Op Msg_type Msg_text
......
......@@ -924,7 +924,7 @@ static bool mysql_admin_table(THD* thd, TABLE_LIST* tables,
appropriate action is to just not collect EITS stats for this command.
*/
collect_eis=
(table->table->s->table_category == TABLE_CATEGORY_USER &&
(tab->s->table_category == TABLE_CATEGORY_USER && !tab->s->sequence &&
!(lex->alter_info.partition_flags & ALTER_PARTITION_ADMIN) &&
(check_eits_collection_allowed(thd) ||
lex->with_persistent_for_clause));
......
......@@ -3268,7 +3268,8 @@ read_statistics_for_tables(THD *thd, TABLE_LIST *tables, bool force_reload)
TABLE_SHARE *table_share;
/* Skip tables that can't have statistics. */
if (tl->is_view_or_derived() || !table || !(table_share= table->s))
if (tl->is_view_or_derived() || !table || !(table_share= table->s) ||
table_share->sequence)
continue;
/* Skip temporary tables */
if (table_share->tmp_table != NO_TMP_TABLE)
......
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