in reply to DBI (Prepare once execute many fails)

I'll echo their statements again....in all databases I've done perl dbi work in.. .Oracle, MySQL, and Access....they all seemed to have side effects if I didn't explicitly call finish. Remember however that if you call finish before your fetchrow_array call.. that it will fail due to the cursor not being valid. usual flow
$sth = $dbh->prepare($query); $sth->execute(); while(my @row = $sth->fetchrow_array) { #do stuff } $sth->finish();