summaryrefslogtreecommitdiff
path: root/mysql-test/main/stat_tables_missing.result
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2019-06-06 17:10:57 +0200
committerSergei Golubchik <serg@mariadb.org>2019-06-07 18:41:08 +0200
commit973b281e599e6126c58c8398211dfe306644e517 (patch)
tree02a86ec9908aae6e6d593d3217ece7bcafba5505 /mysql-test/main/stat_tables_missing.result
parent06291c3f36c6b768e6ce1db986a0f103abe71b57 (diff)
downloadmariadb-git-973b281e599e6126c58c8398211dfe306644e517.tar.gz
MDEV-18788 Live upgrade from MySQL 5.6/5.7 to MariaDB 10.4 fails with "Event Scheduler: An error occurred when initializing system tables"
if columns or indexes are modified/renamed/dropped in an ALTER TABLE, stat tables must be updated accordingly (e.g. all statistics for a column should be dropped). But if a stat table doesn't exist, it's not a reason to fail the whole ALTER TABLE operation - such an error should be ignored.
Diffstat (limited to 'mysql-test/main/stat_tables_missing.result')
-rw-r--r--mysql-test/main/stat_tables_missing.result11
1 files changed, 11 insertions, 0 deletions
diff --git a/mysql-test/main/stat_tables_missing.result b/mysql-test/main/stat_tables_missing.result
new file mode 100644
index 00000000000..a7cd35b1d1f
--- /dev/null
+++ b/mysql-test/main/stat_tables_missing.result
@@ -0,0 +1,11 @@
+create table t1 (a int);
+alter table mysql.column_stats rename to mysql.column_stats1;
+flush tables;
+alter table t1 change a b varchar(100);
+show create table t1;
+Table Create Table
+t1 CREATE TABLE `t1` (
+ `b` varchar(100) DEFAULT NULL
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
+alter table mysql.column_stats1 rename to mysql.column_stats;
+drop table t1;