I am running a simple loop in perl which does an update to an oracle table. The updates are not taking unless I disconnect from the database and reconnect. I have a finish command at the end of the loop. Any ideas?
$sql="UPDATE $table SET X='$value' WHERE Y='$where'";
$sth = $dbh->prepare($sql);
$sth->execute;
$sth->finish();
#&disconnect;
#&connect; #only works if these two lines are not commented