in reply to Re: Re: Sqlite DBI $sth->rows
in thread Sqlite DBI $sth->rows

The success of the connect most certainly does not need to be checked explicitly, that is, by both setting RaiseError and calling die yourself - DBI.pm does it for you:

DBI.pm (version 1.38)
358: sub connect {
...
416: unless ($dbh = $drh->$connect_meth($dsn, $user, $pass, $attr)) {
        my $msg = "$class->connect($dsn) failed: ".$drh->errstr;
        if (ref $attr) {
            Carp::croak($msg) if $attr->{RaiseError};
            Carp::carp ($msg) if $attr->{PrintError};
        }
        DBI->trace_msg("       $msg\n");
        $! = 0; # for the daft people who do DBI->connect(...) || die "$!";
        return undef;
    }
...

jeffa

L-LL-L--L-LL-L--L-LL-L--
-R--R-RR-R--R-RR-R--R-RR
B--B--B--B--B--B--B--B--
H---H---H---H---H---H---
(the triplet paradiddle with high-hat)