my $sth = $dbi->prepare( "SELECT * FROM table" ) or die DBI->errstr; $sth->execute( ) or die DBI->errstr;