PT-1638 Fixed MariaDB support

Because https://bugs.mysql.com/bug.php?id=89441 pt-osc with --drop-swap
doesn't work with MySQL 8.0+ (it will be fixed in MySQL 8.0.14) but it
should work with MariaDB 10.
Fixed version comparison to include the MySQL 'flavor'.
This commit is contained in:
Carlos Salguero
2018-11-12 09:34:40 -03:00
parent eb6beefd90
commit 348c105639
2 changed files with 2 additions and 1 deletions

View File

@@ -9817,7 +9817,8 @@ sub main {
}
}
if ($server_version >= '8.0' && $alter_fk_method eq 'drop_swap') {
my $vp = VersionParser->new($cxn->dbh());
if ($vp->cmp('8.0') > -1 && $vp->flavor() !~ m/maria/i && $alter_fk_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);

Binary file not shown.