* Steven Mackenzie <[EMAIL PROTECTED]> [2006-06-27 18:45]:
> In some Class::DBI code, I have this in my table base class:
> 
> __PACKAGE__->set_sql("delete_all", <<"");
> DELETE FROM __TABLE__ WHERE 1=1

Note that you can omit that `WHERE` clause completely. It’s legal
syntax to say `DELETE FROM $table`.

Regards,
-- 
Aristotle Pagaltzis // <http://plasmasturm.org/>

_______________________________________________
List: http://lists.rawmode.org/cgi-bin/mailman/listinfo/dbix-class
Wiki: http://dbix-class.shadowcatsystems.co.uk/
IRC: irc.perl.org#dbix-class
SVN: http://dev.catalyst.perl.org/repos/bast/trunk/DBIx-Class/
Searchable Archive: http://www.mail-archive.com/[email protected]/

Reply via email to