mirror of
https://github.com/percona/percona-toolkit.git
synced 2026-04-17 01:01:39 +08:00
Added changes suggested by mbenshoof, michaeldg
- Fixed issue with dry run and preserve triggers - Fixed issue with trim multiline - Changed DSNParser in lib
This commit is contained in:
@@ -9554,7 +9554,9 @@ sub main {
|
||||
if ($orig_trigger ne '') {
|
||||
PTDEBUG && _d($orig_trigger);
|
||||
print $orig_trigger, "\n" if $o->get('print');
|
||||
$cxn->dbh()->do($orig_trigger);
|
||||
if ( $o->get('execute') ) {
|
||||
$cxn->dbh()->do($orig_trigger);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -11108,7 +11110,7 @@ sub terminate_sql {
|
||||
sub trim {
|
||||
my ( $text ) = @_;
|
||||
die "I need a text argument" unless defined $text;
|
||||
$text =~ s/^\s+|\s+$//gm;
|
||||
$text =~ s/^\s+|\s+$//g;
|
||||
return $text;
|
||||
}
|
||||
|
||||
|
||||
@@ -276,6 +276,7 @@ sub get_dbh {
|
||||
PrintError => 0,
|
||||
ShowErrorStatement => 1,
|
||||
mysql_enable_utf8 => ($cxn_string =~ m/charset=utf8/i ? 1 : 0),
|
||||
mysql_multi_statements => 1,
|
||||
};
|
||||
@{$defaults}{ keys %$opts } = values %$opts;
|
||||
if (delete $defaults->{L}) { # L for LOAD DATA LOCAL INFILE, our own extension
|
||||
|
||||
Reference in New Issue
Block a user