Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.
UltraLite provides transaction processing to ensure the integrity of the data in your database. A transaction is a logical unit of work. Either the entire transaction is executed, or none of the statements in the transaction are executed.
By default, UltraLite operates in AutoCommit mode. In AutoCommit mode, each insert, update, or delete is executed as a separate transaction. Once the operation is completed, the change is made to the database.
If you set the ULConnection.AutoCommit property to false, you can use multi-statement transactions. For example, if your application transfers money between two accounts, the deduction from the source account and the addition to the destination account constitute a single transaction. If AutoCommit is false, you must execute a ULConnection.Commit statement to complete a transaction and make changes to your database permanent, or you may execute a ULConnection.Rollback statement to cancel all the operations of a transaction. Turning off AutoCommit improves performance.
Synchronization causes a Commit even if AutoCommit is set to False.