line |
true |
false |
branch |
18
|
1 |
2 |
if exists $param{-'dbh'} and $param{-'dbh'} |
19
|
1 |
2 |
if (exists $param{-'connector'} and my $cname = delete $param{-'connector'}) |
20
|
1 |
0 |
if "$cname" eq '1' |
24
|
0 |
1 |
if (@_) |
25
|
0 |
0 |
@_ > 1 ? : |
30
|
1 |
0 |
if (exists $param{-'dbh'} and my $hname = delete $param{-'dbh'}) |
31
|
1 |
0 |
if "$hname" eq '1' |
34
|
0 |
0 |
if (@_) |
35
|
0 |
0 |
@_ > 1 ? : |
39
|
0 |
0 |
if defined $self->{$hname} and $self->{$hname}->ping |
45
|
0 |
3 |
if (%param and %{$pkg->Defaults;}) |
52
|
0 |
0 |
unless $ps eq $ds |
54
|
2 |
1 |
if %param |
57
|
0 |
3 |
if exists $param{'TraceLevel'} and defined $param{'TraceLevel'} |
103
|
3 |
2 |
ref $proto ? : |
104
|
15 |
5 |
if ref $proto |
111
|
0 |
0 |
unless @args and $args[0] =~ /^DBI:/i |
114
|
0 |
0 |
unless (eval {
do {
$dbh = $class->SUPER::connect(@args)
}
}) |
123
|
0 |
0 |
if ($$self{"dbh.$tag"} //= $self->connect)->ping |
132
|
0 |
2 |
if (my $cnf = $param->cnf) |
134
|
0 |
0 |
unless $cnf =~ /\.cnf$/ |
135
|
0 |
0 |
if not -r $cnf and defined $param->cnfdir |
136
|
0 |
0 |
unless -f $cnf and -r $cnf |
139
|
0 |
0 |
if defined $param->cnfgroup |
147
|
0 |
2 |
%custom ? : |
153
|
0 |
2 |
defined $param->host ? : |
|
2 |
0 |
defined $param->port ? : |
165
|
0 |
0 |
unless @args |
167
|
0 |
0 |
if ($args[2] and $_ = length $args[2] and $_ > 1) |
221
|
0 |
0 |
if @_ >= 2 or @_ == 1 and $_[0] ne 'have_innodb' |
229
|
0 |
0 |
if exists $variables->{'ignore_builtin_innodb'} and ($variables->{'ignore_builtin_innodb'} // '') eq 'ON' |
231
|
0 |
0 |
if @_ == 1 and $_[0] eq 'have_innodb' |
257
|
0 |
0 |
if defined $args[0] |
258
|
0 |
0 |
unless $schemata = $self->selectcol_arrayref($sql, $args[1]) |
262
|
0 |
0 |
unless (eval {
do {
my $sql = 'SHOW DATABASES';
$sql .= sprintf(q[ LIKE '%s'], $args[0]) if defined $args[0];
die unless $schemata = $self->selectcol_arrayref($sql, $args[1]);
@$schemata = grep((!/^(?:\#|lost\+found)/), @$schemata);
1
}
}) |
282
|
0 |
0 |
unless (eval {
do {
my $sth = $self->table_info('', @args);
@$tables = map($_->[2], @{$sth->fetchall_arrayref;});
1
}
}) |
307
|
0 |
0 |
if (defined $opts) { } |
319
|
0 |
0 |
if @$rs >= 1 and @{$rs->[0];} != 2 |
335
|
0 |
0 |
if ($_->[1] eq 'DEFAULT') { } |
340
|
0 |
0 |
$_->[1] eq 'YES' ? : |
359
|
0 |
0 |
if ($self->mysqld_version =~ /^(\d+)\./ and $1 >= 5) |
376
|
0 |
0 |
unless defined $schema and length $schema |
377
|
0 |
0 |
unless defined $table and length $table |
389
|
0 |
0 |
unless defined $schema and length $schema |
392
|
0 |
0 |
if defined $table_pattern |
402
|
0 |
0 |
unless $engine =~ /^\w+$/ |
405
|
0 |
0 |
$major == 5 && $minor >= 1 ? : |
|
0 |
0 |
$major > 5 ? : |
414
|
0 |
0 |
if ($line =~ /^-+$/ and length $buffer) { } |
|
0 |
0 |
elsif ($line =~ /^-+$/) { } |
|
0 |
0 |
elsif (not length $title) { } |
|
0 |
0 |
elsif ($line =~ /^=+$/) { } |
454
|
0 |
0 |
unless eval {
do {
($space) = $self->selectrow_array("SELECT CONCAT(TRUNCATE(DATA_FREE / 1024, 0), ' kB')\nFROM information_schema.TABLES\nWHERE\n TABLE_SCHEMA = ?\n AND TABLE_NAME = ?", undef, $schema, $table);
$space ne '0 kB'
}
} |
456
|
0 |
0 |
if $comment =~ /InnoDB free: (\d+ \w+)/ |
480
|
0 |
0 |
if ($repl->{'Slave_SQL_Running'} // '') =~ /^Yes/i |
495
|
0 |
0 |
if ($state =~ /^Modified db pages\s+(\d+)$/m) { } |
496
|
0 |
0 |
if $1 == 0 |
504
|
0 |
0 |
unless (eval {
do {
$self->global_var('innodb_max_dirty_pages_pct', 0);
$self->do('FLUSH TABLES WITH READ LOCK');
my($quiesced, $count) = (0, 0);
while (++$count < $self->quiesce_timeout) {
my $state = $self->engine_status('InnoDB')->{'buffer_pool_and_memory'};
if ($state =~ /^Modified db pages\s+(\d+)$/m) {
++$quiesced, last if $1 == 0;
}
else {
die "Failed to check dirty pages\n";
};
sleep 1;
};
$quiesced
}
}) |
518
|
0 |
0 |
unless (@_) |
525
|
0 |
0 |
unless (@_) |
538
|
0 |
0 |
unless &looks_like_number($value) |
544
|
0 |
0 |
unless (eval {
do {
($old) = $self->selectrow_array(sprintf('SELECT @@%s.%s', $scope, $var));
$value = "'${value}'" unless &looks_like_number($value);
$self->do("SET $scope $var = $value");
($new) = $self->selectrow_array(sprintf('SELECT @@%s.%s', $scope, $var));
1
}
}) |
548
|
0 |
0 |
wantarray ? : |