Skip to content
yuki-kimoto edited this page Sep 26, 2012 · 1 revision

update all rows

DBIx::Custom Documents >

Update all rows by update_all method.

$dbi->update_all({title => 'Perl', author => 'Ken'}, table => 'book');

First argument is updated data which is hash reference. table opition is set to the table name. The following SQL is executed.

update book set title = ?, author = ?;

Correspongind values is enbdded into place holder.

Clone this wiki locally