The default "do" method is logically similar to: sub do { my ($dbh, $statement, $attr, @bind_values) = @_; my $sth = $dbh->prepare ($statement, $attr) or return undef; $sth->execute (@bind_values) or return undef; my $rows = $sth->rows; ($rows == 0) ? "0E0" : $rows; # always return true if no error } # do