my $sth=$dbh->prepare('UPDATE ... SET foo=? ...'); for my $entry (@data) { $sth->execute($entry); } $sth->finish();