$sqlquery = "SOME UPDATE STATEMENT"; my $newsth = $dbh->prepare($sqlquery); $newsth->execute or die "3"; #### $SIG{__DIE__} = sub { print $query->redirect(-location=>"$redirecturl?error=@_"); };