A transaction is a group of SQL commands executed together as a single component of work to be accomplished. If all of these commands succeed, then a transaction is committed - the changes to the data are made final. If any of the commands within a transaction fail, then the entire transaction is cancelled, or in SQL Server terms, the transaction will be rolled back.
Transactions are one of the things that keep your data safe, but they're not necessarily easy to understand. Here's some help:
View Complete Post