php - Multiple commands atomically -
i'm using php , mysql call couple of commands. there group-employee cross-reference table, , employees may added or removed group. i'm writing feature first removing employees , adding in each employee in table if group modified. want make sure commands go through or else have table roll back. how can make sure commands happen atomically?
you're looking transactions unless i'm mistaken.
here's great place start: http://dev.mysql.com/doc/refman/5.0/en/sql-syntax-transactions.html
Comments
Post a Comment