PT-1554 Fixed tests for duplicate key checker

This commit is contained in:
Carlos Salguero
2018-06-14 10:45:36 -03:00
parent accdd7712b
commit 5a47bac4d4
3 changed files with 4 additions and 2 deletions

View File

@@ -1,5 +1,6 @@
Changelog for Percona Toolkit
* Improvement PT-1569 : Disabled --alter-foreign-keys-method=drop_swap in pt-osc
* Fixed bug PT-1563 : Fixed pt-show-grants for MySQL 5.6
* Improvement PT-1562 : pt-mysql-summary: Fix mysqld command for Travis
* Improvement PT-242 : (pt-stalk) Include SHOW SLAVE STATUS on 5.7 (Thanks Marcelo Altmann)

View File

@@ -8510,7 +8510,8 @@ sub main {
die "This tool requires MySQL 5.0.10 or newer.\n";
}
if ($server_version >= '8.0' && $o->get('alter-foreign-keys-method') eq 'drop_swap') {
if ($server_version >= '8.0' && ($o->has('alter-foreign-keys-method') &&
$o->get('alter-foreign-keys-method') || "" eq 'drop_swap')) {
my $msg = "--alter-foreign-keys-method=drop_swap doesn't work with MySQL 8.0+\n".
"See https://bugs.mysql.com/bug.php?id=89441";
die($msg);

View File

@@ -12,7 +12,7 @@
# UNIQUE KEY `domain` (`domain`),
# UNIQUE KEY `unique_key_domain` (`domain`)
# Column types:
# `domain` varchar(175) character set utf8 collate utf8_bin not null
# `domain` varchar(175) collate utf8_bin not null
# To remove this duplicate index, execute:
ALTER TABLE `test`.`domains` DROP INDEX `domain`;