Hi all, I'm working with tables stored by the InnoDB engine and would like to be able to commit only if there are no errors generated by a group of statements like this.
/* -*- sql -*- */ SET AUTOCOMMIT=0; use db1; begin work; sql statement 1; sql statement 2; . . . sql statement n; At this point I'd like to say, in sql, if no errors then commit; else rollback end From what I read in the manual I can do one or the other (commit or rollback) but there didn't seem to be a way of conditionally doing one or the other of them. Thanks in advance, -- _\\|//_ ( O-O ) ---------------------------o00--(_)--00o------------------------------ Colm G. Connolly | Tel : +353-1-716-2851 Department of Computer Science | Fax : +353-1-269-7262 University College Dublin (UCD) | Web : http://darwin.ucd.ie/ Belfield, Dublin 4 | MSN : [EMAIL PROTECTED] Éire / Republic of Ireland | -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]