As noted above, you call
$dbh->do("update table set thing = ? where id = ?",
\%attr, $thing, $id);
What you pass in \%attr is interesting and not particularly
obvious, though. Provided you don't want to pass any
attributes (I've never needed to) you can pass
undef or
{ } whichever
takes your fancy. Eg :-
$dbh->do("update table set thing = ? where id = ?",
undef, $thing, $id);
# OR
$dbh->do("update table set thing = ? where id = ?",
{}, $thing, $id);
I usually encapsulate it in a little function though
so I can just print out the values of the updates
in debug mode!