$insertstr = ("update table set col1= ? where col2 = ?); $rows_affected = $dbh->do($insertstr, undef, $val1, $val2)