in reply to DBI inserts and what not
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 = ?", \%attr, $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!$dbh->do("update table set thing = ? where id = ?", undef, $thing, $id); # OR $dbh->do("update table set thing = ? where id = ?", {}, $thing, $id);
|
|---|