Branch Coverage

blib/lib/DBI/BabyConnect.pm
Criterion Covered Total %
branch 5 576 0.8


line true false branch
265 0 1 if $enableCaching
266 0 1 if $disableDestroy
299 0 0 if ($ENABLE_CACHING)
303 0 0 if ($s1 eq $_)
332 0 0 if (ref $conf eq 'HASH') { }
0 0 elsif (-f $conf) { }
0 0 elsif (exists $$db_ref{$conf}) { }
349 0 0 unless $dbR{$conf}
373 0 0 if not $driver and $_ =~ /$drv/i
375 0 0 if not $driver and $_ =~ /ODBC/i
376 0 0 unless $driver
379 0 0 unless defined $$dbiParams{'Server'}
383 0 0 if $$dbiParams{'Driver'}
384 0 0 if $$dbiParams{'DataName'}
385 0 0 if $$dbiParams{'Server'}
406 0 0 if (not $dbiconnection) { }
455 0 0 $$dbiParams{'Driver'} =~ /Mysql/i ? :
0 0 $$dbiParams{'Driver'} =~ /Oracle/i ? :
461 0 0 $$self{'dbb'} eq 'ora' ? :
481 0 0 if $ENABLE_CACHING and ${$CACHED_CONN{$$ . $conf};}{'class'} = $self
498 0 0 if (defined $deb and $deb ne '') { }
500 0 0 %h ? :
505 0 0 if ($level) { }
534 0 0 if (defined $errlog and $errlog ne '') { }
536 0 0 %h ? :
574 0 0 unless defined $$dbiParams{'Server'}
582 0 0 if (not $dbiconnection) { }
631 0 0 @_ ? :
634 0 0 if $bean_flags
662 0 0 if $wanthash and (%$bean_flags) = map({$_, $$t_bean_flags{$_};} keys %$t_bean_flags)
732 0 0 if (@_) { }
746 0 0 if (@_) { }
759 0 0 if (@_) { }
787 0 0 if (@_)
801 0 0 if (@_)
815 0 0 if (@_)
838 0 0 if (@_)
852 0 0 if (@_)
866 0 0 if (@_)
881 0 0 if (@_)
894 0 0 if (@_)
907 0 0 if (@_)
919 0 0 if (@_)
930 0 0 if (@_)
946 0 0 unless open F, "$conf"
949 0 0 unless ($line =~ /^#/ or $line =~ /^$/)
954 0 0 if $head eq $_
982 0 0 unless open F, "$conf"
986 0 0 unless ($line =~ /^#/ or $line =~ /^$/)
992 0 0 if $head eq $_
1026 0 0 unless $$db_ref{$lookup_db_descriptor}
1039 0 0 if defined $$conf{$k}
1044 0 0 if defined $$conf{$k}
1077 0 0 if defined $$conf{$k}
1083 0 0 if defined $$conf{$k}
1099 0 0 unless $$class{'debhook'}
1142 0 0 unless $$class{'debhook'}
1165 0 0 unless $$class{'debhook'}
1181 0 0 unless $$class{'debhook'}
1208 0 0 @_ ? :
1213 0 0 unless open F, "<$SCHEMA_FILENAME"
1216 0 0 if $_ =~ /^\s*--/
1222 0 0 if $dbtablespec =~ /<<>>/
1224 0 0 if defined $ATTRIBUTES
1230 0 0 if ($dbtablespec =~ /\~/) { }
1233 0 0 if (length $sql > 1 and $sql =~ /drop/i) { }
0 0 elsif (length $sql > 1) { }
1247 0 0 unless defined $class->do($sql)
1271 0 0 unless defined $$class{'connection'}->do($dbtablespec)
1292 0 0 if ($dbtablespec =~ /\~/) { }
1295 0 0 if (length $sql > 1 and $sql =~ /drop/i) { }
0 0 elsif (length $sql > 1) { }
1310 0 0 unless defined $class->do($sql)
1333 0 0 unless defined $$class{'connection'}->do($dbtablespec)
1355 0 0 unless defined $oncol
1357 0 0 defined $s && $s ne '' ? :
1371 0 0 if ($DBI::err)
1380 0 0 if (my $temp = $$class{'cursor'}->fetchrow_hashref)
1409 0 0 if ($h{$key} ne '') { }
1415 0 0 if ($type eq 't' or $type eq 'T' or $type eq 'd' or $type eq 'D' or $type eq 'n' or $type eq 'N' or $h{$key} eq 'NULL') { }
1444 0 0 if ($$class{'cursor'}->execute) { }
1499 0 0 if (ref $h{$key} eq 'SCALAR') { }
1519 0 0 if $class->printerror == 0
1520 0 0 if $class->raiseerror == 0
1523 0 0 if $class->autocommit == 0
1532 0 0 if ($$class{'cursor'}->execute(@bind_data_bins)) { }
1551 0 0 if $class->autorollback
1552 0 0 unless $xprm{'ON_FAILED_DBIEXECUTE_ROLLBACK_AND_EXIT'}
1563 0 0 if $xprm{'ON_FAILED_DBIEXECUTE_ROLLBACK_AND_EXIT'} and $PERSISTENT_OBJECT_ENABLED
1564 0 0 if $xprm{'ON_FAILED_DBIEXECUTE_ROLLBACK_AND_EXIT'}
1584 0 0 if $class->printerror == 0
1585 0 0 if $class->raiseerror == 0
1588 0 0 if $class->autocommit == 0
1596 0 0 if (@_)
1603 0 0 ref $_ eq 'SCALAR' ? :
1608 0 0 if ($$class{'cursor'}->execute(@bind_data_bins)) { }
1621 0 0 if ($class->autorollback and not $class->autocommit) { }
1656 0 0 @_ && ref $_[0] eq 'ARRAY' && ref ${$_[0];}[0] eq 'HASH' ? :
1657 0 0 @_ && ref $_[0] eq 'HASH' ? :
1664 0 0 if $class->printerror == 0
1665 0 0 if $class->raiseerror == 0
1668 0 0 if $class->autocommit == 0
1675 0 0 if (ref $o_bnd eq 'ARRAY' and ref $$o_bnd[0] eq 'HASH') { }
1685 0 0 unless my $cursor = $$class{'connection'}->prepare($q)
1690 0 0 ref $$o_bnd[$i] eq 'SCALAR' ? :
1696 0 0 if (exists $$o_typ{$ord{$i}}) { }
1708 0 0 unless $cursor->execute
1715 0 0 if (@_)
1719 0 0 ref $_ eq 'SCALAR' ? :
1724 0 0 if ($$class{'cursor'}->execute(@bind_data_bins)) { }
1737 0 0 if ($class->autorollback and not $class->autocommit) { }
1792 0 0 if ($$El2Ty_href{$_} =~ /STRING/i and not $$El2Ty_href{$_} =~ /STRING\(\s*\^\s*\)/i) { }
0 0 elsif ($$El2Ty_href{$_} =~ /STRING\(\s*\^\s*\)/) { }
0 0 elsif ($$El2Ty_href{$_} =~ /CBOOL/) { }
1794 0 0 $$CoL_href{$_} eq '' && $xprm{'DBSETTING_FORCE_SINGLESPACE_FOR_EMPTY_STRING'} ? :
1843 0 0 if (ref $o_bnd eq 'ARRAY' and ref $$o_bnd[0] eq 'HASH')
1849 0 0 ref $$o_bnd[$i] eq 'SCALAR' ? :
1850 0 0 if (exists $$o_typ{$ord{$i}}) { }
1869 0 0 if $class->printerror == 0
1870 0 0 if $class->raiseerror == 0
1874 0 0 if $class->autocommit == 0
1881 0 0 if ($class->sqlbnd($SQL, $o_bnd)) { }
1921 0 0 if $class->printerror == 0
1922 0 0 if $class->raiseerror == 0
1926 0 0 if $class->autocommit == 0
1952 0 0 if ($$El2Ty_href{$_} =~ /STRING/i and not $$El2Ty_href{$_} =~ /STRING\(\s*\^\s*\)/i) { }
0 0 elsif ($$El2Ty_href{$_} =~ /STRING\(\s*\^\s*\)/) { }
0 0 elsif ($$El2Ty_href{$_} =~ /CBOOL/) { }
1954 0 0 $$CoL_href{$_} eq '' && $xprm{'DBSETTING_FORCE_SINGLESPACE_FOR_EMPTY_STRING'} ? :
2012 0 0 if (ref $o_bnd eq 'ARRAY' and ref $$o_bnd[0] eq 'HASH')
2018 0 0 ref $$o_bnd[$i] eq 'SCALAR' ? :
2019 0 0 if (exists $$o_typ{$ord{$i}}) { }
2033 0 0 if ($class->sqlbnd($SQL, $o_bnd)) { }
2083 0 0 if $class->printerror == 0
2084 0 0 if $class->raiseerror == 0
2088 0 0 if $class->autocommit == 0
2114 0 0 $rr_do ? :
0 0 defined $rr_do && $rr_do eq '0E0' ? :
2122 0 0 if $class->raiseerror == 0 and not defined $rr and $q =~ /^\s*drop\s+/i
2124 0 0 if (defined $rr) { }
2132 0 0 if ($xprm{'ENABLE_STATISTICS_ON_DO'})
2134 0 0 defined $$class{'_qryStat'}{$q} ? :
2146 0 0 if $class->autorollback
2147 0 0 unless $xprm{'ON_FAILED_DBIEXECUTE_ROLLBACK_AND_EXIT'}
2158 0 0 if $xprm{'ON_FAILED_DBIEXECUTE_ROLLBACK_AND_EXIT'} and $PERSISTENT_OBJECT_ENABLED
2159 0 0 if $xprm{'ON_FAILED_DBIEXECUTE_ROLLBACK_AND_EXIT'}
2187 0 0 if $class->printerror == 0
2188 0 0 if $class->raiseerror == 0
2196 0 0 if (ref $o eq 'ARRAY' and ref $$o[0] eq 'HASH') { }
2206 0 0 unless my $cursor = $$class{'connection'}->prepare($sql)
2210 0 0 if ($$o[$i]) { }
2219 0 0 unless $cursor->execute
2222 0 0 if ($$o[1])
2227 0 0 if ($xprm{'ENABLE_STATISTICS_ON_SPC'})
2229 0 0 defined $$class{'_spcStat'}{$pkgspc} ? :
2243 0 0 unless my $cursor = $$class{'connection'}->prepare($sql)
2246 0 0 unless $cursor->execute($o)
2253 0 0 if ($xprm{'ENABLE_STATISTICS_ON_SPC'})
2255 0 0 defined $$class{'_spcStat'}{$pkgspc} ? :
2290 0 0 if ($elements =~ /,/)
2308 0 0 if ($elements =~ /,/) { }
2315 0 0 if $s =~ /:$/
2398 0 0 @_ ? :
2409 0 0 if ($DBI::err)
2418 0 0 if (my $temp = $$class{'cursor'}->fetchrow_hashref) { }
2420 0 0 if (@{$list;}) { }
2449 0 0 ref $_[0] eq 'HASH' ? :
2452 0 0 ref $_[0] eq 'ARRAY' ? :
2456 0 0 if $list and $q =~ /SELECT\s+\*\s+/i
2463 0 0 if $class->printerror == 0
2464 0 0 if $class->raiseerror == 0
2485 0 0 if ($DBI::err)
2494 0 0 if ($list) { }
0 0 elsif (my $temp = $$class{'cursor'}->fetchrow_hashref) { }
2506 0 0 if ($$class{'cursor'}->rows) { }
2561 0 0 @_ && ref $_[0] eq 'ARRAY' ? :
2563 0 0 @_ && ref $_[0] eq 'ARRAY' && defined ${$_[0];}[0] ? :
2566 0 0 if ref $_[0] eq 'HASH'
2573 0 0 if $class->printerror == 0
2574 0 0 if $class->raiseerror == 0
2595 0 0 if $@
2599 0 0 if (not $recalled and $$extras{'INCLUDE_HEADER'} || !defined($$extras{'INCLUDE_HEADER'}))
2619 0 0 if $cnt % 100 == 0
2620 0 0 if $$extras{'MAX_ROWS'} and $cnt >= $$extras{'MAX_ROWS'} and $$class{'cursor'}->finish
2630 0 0 if $cnt == -1
2649 0 0 @_ && ref $_[0] eq 'ARRAY' ? :
2659 0 0 if (ref $selection eq 'ARRAY') { }
0 0 elsif (ref $selection eq 'HASH') { }
0 0 elsif ($selection =~ /^[\s]*\*[\s]*$/) { }
0 0 elsif ($selection =~ /\w/) { }
2702 0 0 if (defined $where and length $where and not $where =~ /^\s+$/) { }
2713 0 0 if $class->printerror == 0
2714 0 0 if $class->raiseerror == 0
2732 0 0 if $@
2759 0 0 if ($seeked eq 'all' or $seeked eq 'array' or $seeked eq 'listed' or $seeked eq 'skeemamap')
2795 0 0 if $i == -1
2818 0 0 @_ ? :
2827 0 0 if (ref $selection eq 'ARRAY') { }
0 0 elsif (ref $selection eq 'HASH') { }
0 0 elsif ($selection =~ /^[\s]*\*[\s]*$/) { }
0 0 elsif ($selection =~ /\w/) { }
2870 0 0 if (defined $where and length $where and not $where =~ /^\s+$/) { }
2883 0 0 if $class->printerror == 0
2884 0 0 if $class->raiseerror == 0
2905 0 0 if ($seeked eq 'all' or $seeked eq 'listed' or $seeked eq 'skeemamap') { }
0 0 elsif ($seeked eq 'array') { }
2940 0 0 if $i == -1
2956 0 0 if $class->printerror == 0
2957 0 0 if $class->raiseerror == 0
2961 0 0 if $class->autocommit == 0
2968 0 0 if ($@)
2988 0 0 if $class->printerror == 0
2989 0 0 if $class->raiseerror == 0
2993 0 0 if $class->autocommit == 0
2999 0 0 if (not $class->is_AutoCommit and $class->is_AutoRollback) { }
3003 0 0 if ($@)
3035 0 0 if ($PERSISTENT_OBJECT_ENABLED)
3050 0 0 if $xprm{'PRT_CEND'}
3056 0 0 if $xprm{'CALLER_DISCONNECT'} and $class->state eq 'DISCONNECTED'
3063 0 0 if $xprm{'CALLER_DISCONNECT'} and $class->state eq 'UNDEF'
3078 0 0 unless ($$class{'connection'}->disconnect)
3083 0 0 if $xprm{'PRT_CEND'}
3100 0 0 unless $$class{'debhook'}
3118 0 0 @_ ? :
3127 0 0 if ($PERSISTENT_OBJECT_ENABLED and not $FORCE_USUAL_DESTRUCTION)
3128 0 0 if (not $class->is_RaiseError || $class->is_AutoCommit and $class->is_AutoRollback and $class->_internal_state eq -1)
3136 0 0 unless $class->rollback
3175 0 0 @_ ? :
3184 0 0 if ($PERSISTENT_OBJECT_ENABLED and not $FORCE_USUAL_DESTRUCTION)
3185 0 0 if (not $class->is_RaiseError || $class->is_AutoCommit and $class->is_AutoRollback and $class->_internal_state eq -1)
3193 0 0 unless $class->rollback
3214 0 0 if ($xprm{'CALLER_DISCONNECT'} and $class->state eq 'DISCONNECTED') { }
0 0 elsif ($class->state eq 'UNDEF') { }
0 0 elsif ($xprm{'CALLER_DISCONNECT'} and $class->state eq 'CONNECTED') { }
3228 0 0 if ($class->is_RaiseError and $DBI::err) { }
0 0 elsif (not $class->is_RaiseError || $class->is_AutoCommit and $class->is_AutoRollback and $class->_internal_state eq -1) { }
3229 0 0 if $xprm{'PRT_CEND'}
3230 0 0 if $class->is_AutoRollback and not $class->is_AutoCommit
3233 0 0 unless $$class{'connection'}->disconnect
3250 0 0 if $xprm{'PRT_CEND'}
3251 0 0 if $xprm{'PRT_CEND'}
3252 0 0 unless $class->rollback
3254 0 0 unless $$class{'connection'}->disconnect
3263 0 0 if $xprm{'PRT_CEND'}
3264 0 0 if $xprm{'PRT_CEND'}
3326 0 0 @_ ? :
3339 0 0 if ref $rshr eq 'HASH' and (%$rshr) = map({$_, $$statCC{$_};} keys %$statCC)
3341 0 0 if length $rshr > 2 and (%$th) = map({$_, $$statCC{$_};} keys %{$$statCC{$rshr};})
3415 6 4 if length $value == 1
3440 0 0 @_ ? :
3443 0 0 if ref $rshr eq 'HASH' and (%$rshr) = map({$_, $$class{'_qryStat'}{$_};} keys %{$$class{'_qryStat'};})
3444 0 0 if length $rshr > 2 and (%$th) = map({$_, $$class{'_qryStat'}{$_};} keys %{${$$class{'_qryStat'};}{$rshr};})
3465 0 0 @_ ? :
3468 0 0 if ref $rshr eq 'HASH' and (%$rshr) = map({$_, $$class{'_spcStat'}{$_};} keys %{$$class{'_spcStat'};})
3469 0 0 if length $rshr > 2 and (%$th) = map({$_, $$class{'_spcStat'}{$_};} keys %{${$$class{'_spcStat'};}{$rshr};})
3502 0 0 unless $class->dbdriver =~ /Mysql/i
3531 0 0 unless $class->dbdriver =~ /Mysql/i
3540 0 0 unless defined $_
3588 0 22 if defined $inv{$val}
3609 0 0 unless $class->dbdriver =~ /Mysql/i
3687 0 0 unless $class->dbdriver =~ /Oracle/i
3735 0 0 unless $class->dbdriver =~ /Mysql/i
3852 0 0 @_ ? :
3854 0 0 $_titlen ? :
3874 0 0 unless (@titmap)
3876 0 0 $labmap ? :
3885 0 0 length $tit <= $len ? :
3914 0 0 @$ah ? :
3925 0 0 @_ ? :
3927 0 0 $_titlen ? :
3953 0 0 unless (@titmap)
3955 0 0 $labmap ? :
3964 0 0 length $tit <= $len ? :
3999 0 0 @$ah ? :
4011 0 0 @_ ? :
4013 0 0 $_titlen ? :
4035 0 0 unless (@titmap)
4038 0 0 $labmap ? :
4047 0 0 length $tit <= $len ? :
4074 0 0 @$aa ? :
4084 0 0 @_ ? :
4089 0 0 $_titlen ? :
4116 0 0 unless (@titmap)
4118 0 0 $labmap ? :
4127 0 0 length $tit <= $len ? :
4161 0 0 @$aa ? :
4200 0 0 unless open $$impl{'handle'}, $args{'file'}
4265 0 0 if $DBI::BabyConnect::Deb::AUTOLOAD =~ /::DESTROY$/