diff options
author | Olivier Bertrand <bertrandop@gmail.com> | 2020-01-11 18:34:57 +0100 |
---|---|---|
committer | Olivier Bertrand <bertrandop@gmail.com> | 2020-01-11 18:34:57 +0100 |
commit | 54449161f8fa953af493f4785305b14fe89af104 (patch) | |
tree | 567293d9dc3539e2857e823e6f1775f1ea83ba25 /mysql-test/r/mysql_tzinfo_to_sql_symlink.result | |
parent | 98f70fa26bc94991767f6c2008dac3fccf14d23c (diff) | |
parent | cb204e11eaf4c473ce5d5a10a21de147430057dc (diff) | |
download | mariadb-git-54449161f8fa953af493f4785305b14fe89af104.tar.gz |
Merge with last MariaDB version
Diffstat (limited to 'mysql-test/r/mysql_tzinfo_to_sql_symlink.result')
-rw-r--r-- | mysql-test/r/mysql_tzinfo_to_sql_symlink.result | 104 |
1 files changed, 84 insertions, 20 deletions
diff --git a/mysql-test/r/mysql_tzinfo_to_sql_symlink.result b/mysql-test/r/mysql_tzinfo_to_sql_symlink.result index 03543244105..fc9ddce08b1 100644 --- a/mysql-test/r/mysql_tzinfo_to_sql_symlink.result +++ b/mysql-test/r/mysql_tzinfo_to_sql_symlink.result @@ -2,9 +2,15 @@ # MDEV-5226 mysql_tzinfo_to_sql errors with tzdata 2013f and above # # Verbose run -set @prep=if((select count(*) from information_schema.global_variables where variable_name='wsrep_on'), 'SET GLOBAL wsrep_replicate_myisam=?', 'do ?'); -prepare set_wsrep_myisam from @prep; -set @toggle=1; execute set_wsrep_myisam using @toggle; +\d | +IF (select count(*) from information_schema.global_variables where +variable_name='wsrep_on' and variable_value='ON') = 1 THEN +ALTER TABLE time_zone ENGINE=InnoDB; +ALTER TABLE time_zone_name ENGINE=InnoDB; +ALTER TABLE time_zone_transition ENGINE=InnoDB; +ALTER TABLE time_zone_transition_type ENGINE=InnoDB; +END IF| +\d ; TRUNCATE TABLE time_zone; TRUNCATE TABLE time_zone_name; TRUNCATE TABLE time_zone_transition; @@ -28,11 +34,25 @@ Warning: Unable to load 'MYSQLTEST_VARDIR/zoneinfo/posix/ignored.tab' as time zo Warning: Skipping directory 'MYSQLTEST_VARDIR/zoneinfo/posix/posix': to avoid infinite symlink recursion. ALTER TABLE time_zone_transition ORDER BY Time_zone_id, Transition_time; ALTER TABLE time_zone_transition_type ORDER BY Time_zone_id, Transition_type_id; -set @toggle=0; execute set_wsrep_myisam using @toggle; +\d | +IF (select count(*) from information_schema.global_variables where +variable_name='wsrep_on' and variable_value='ON') = 1 THEN +ALTER TABLE time_zone ENGINE=MyISAM; +ALTER TABLE time_zone_name ENGINE=MyISAM; +ALTER TABLE time_zone_transition ENGINE=MyISAM; +ALTER TABLE time_zone_transition_type ENGINE=MyISAM; +END IF| +\d ; # Silent run -set @prep=if((select count(*) from information_schema.global_variables where variable_name='wsrep_on'), 'SET GLOBAL wsrep_replicate_myisam=?', 'do ?'); -prepare set_wsrep_myisam from @prep; -set @toggle=1; execute set_wsrep_myisam using @toggle; +\d | +IF (select count(*) from information_schema.global_variables where +variable_name='wsrep_on' and variable_value='ON') = 1 THEN +ALTER TABLE time_zone ENGINE=InnoDB; +ALTER TABLE time_zone_name ENGINE=InnoDB; +ALTER TABLE time_zone_transition ENGINE=InnoDB; +ALTER TABLE time_zone_transition_type ENGINE=InnoDB; +END IF| +\d ; TRUNCATE TABLE time_zone; TRUNCATE TABLE time_zone_name; TRUNCATE TABLE time_zone_transition; @@ -53,39 +73,83 @@ INSERT INTO time_zone_transition_type (Time_zone_id, Transition_type_id, Offset, Warning: Unable to load 'MYSQLTEST_VARDIR/zoneinfo/posix/garbage' as time zone. Skipping it. ALTER TABLE time_zone_transition ORDER BY Time_zone_id, Transition_time; ALTER TABLE time_zone_transition_type ORDER BY Time_zone_id, Transition_type_id; -set @toggle=0; execute set_wsrep_myisam using @toggle; +\d | +IF (select count(*) from information_schema.global_variables where +variable_name='wsrep_on' and variable_value='ON') = 1 THEN +ALTER TABLE time_zone ENGINE=MyISAM; +ALTER TABLE time_zone_name ENGINE=MyISAM; +ALTER TABLE time_zone_transition ENGINE=MyISAM; +ALTER TABLE time_zone_transition_type ENGINE=MyISAM; +END IF| +\d ; # # Testing with explicit timezonefile # -set @prep=if((select count(*) from information_schema.global_variables where variable_name='wsrep_on'), 'SET GLOBAL wsrep_replicate_myisam=?', 'do ?'); -prepare set_wsrep_myisam from @prep; -set @toggle=1; execute set_wsrep_myisam using @toggle; INSERT INTO time_zone (Use_leap_seconds) VALUES ('N'); SET @time_zone_id= LAST_INSERT_ID(); INSERT INTO time_zone_name (Name, Time_zone_id) VALUES ('XXX', @time_zone_id); INSERT INTO time_zone_transition_type (Time_zone_id, Transition_type_id, Offset, Is_DST, Abbreviation) VALUES (@time_zone_id, 0, 0, 0, 'GMT') ; -set @toggle=0; execute set_wsrep_myisam using @toggle; +\d | +IF (select count(*) from information_schema.global_variables where +variable_name='wsrep_on' and variable_value='ON') = 1 THEN +ALTER TABLE time_zone ENGINE=MyISAM; +ALTER TABLE time_zone_name ENGINE=MyISAM; +ALTER TABLE time_zone_transition ENGINE=MyISAM; +ALTER TABLE time_zone_transition_type ENGINE=MyISAM; +END IF| +\d ; # # Testing --leap # -set @prep=if((select count(*) from information_schema.global_variables where variable_name='wsrep_on'), 'SET GLOBAL wsrep_replicate_myisam=?', 'do ?'); -prepare set_wsrep_myisam from @prep; -set @toggle=1; execute set_wsrep_myisam using @toggle; +\d | +IF (select count(*) from information_schema.global_variables where +variable_name='wsrep_on' and variable_value='ON') = 1 THEN +ALTER TABLE time_zone_leap_second ENGINE=InnoDB; +END IF| +\d ; TRUNCATE TABLE time_zone_leap_second; +\d | +IF (select count(*) from information_schema.global_variables where +variable_name='wsrep_on' and variable_value='ON') = 1 THEN +ALTER TABLE time_zone_leap_second ENGINE=MyISAM; +END IF| +\d ; ALTER TABLE time_zone_leap_second ORDER BY Transition_time; -set @toggle=0; execute set_wsrep_myisam using @toggle; +\d | +IF (select count(*) from information_schema.global_variables where +variable_name='wsrep_on' and variable_value='ON') = 1 THEN +ALTER TABLE time_zone ENGINE=MyISAM; +ALTER TABLE time_zone_name ENGINE=MyISAM; +ALTER TABLE time_zone_transition ENGINE=MyISAM; +ALTER TABLE time_zone_transition_type ENGINE=MyISAM; +END IF| +\d ; # # MDEV-6236 - [PATCH] mysql_tzinfo_to_sql may produce invalid SQL # -set @prep=if((select count(*) from information_schema.global_variables where variable_name='wsrep_on'), 'SET GLOBAL wsrep_replicate_myisam=?', 'do ?'); -prepare set_wsrep_myisam from @prep; -set @toggle=1; execute set_wsrep_myisam using @toggle; +\d | +IF (select count(*) from information_schema.global_variables where +variable_name='wsrep_on' and variable_value='ON') = 1 THEN +ALTER TABLE time_zone ENGINE=InnoDB; +ALTER TABLE time_zone_name ENGINE=InnoDB; +ALTER TABLE time_zone_transition ENGINE=InnoDB; +ALTER TABLE time_zone_transition_type ENGINE=InnoDB; +END IF| +\d ; TRUNCATE TABLE time_zone; TRUNCATE TABLE time_zone_name; TRUNCATE TABLE time_zone_transition; TRUNCATE TABLE time_zone_transition_type; ALTER TABLE time_zone_transition ORDER BY Time_zone_id, Transition_time; ALTER TABLE time_zone_transition_type ORDER BY Time_zone_id, Transition_type_id; -set @toggle=0; execute set_wsrep_myisam using @toggle; +\d | +IF (select count(*) from information_schema.global_variables where +variable_name='wsrep_on' and variable_value='ON') = 1 THEN +ALTER TABLE time_zone ENGINE=MyISAM; +ALTER TABLE time_zone_name ENGINE=MyISAM; +ALTER TABLE time_zone_transition ENGINE=MyISAM; +ALTER TABLE time_zone_transition_type ENGINE=MyISAM; +END IF| +\d ; |