From the course: Introduction to SQLite

Unlock this course with a free trial

Join today to access over 25,500 courses taught by industry experts.

Transactions and isolation

Transactions and isolation - SQLite Tutorial

From the course: Introduction to SQLite

Transactions and isolation

- When multiple users or processes are accessing the same SQLite database, you run the risk of changes made by one process affecting others. You can use SQLite's transaction capabilities to manage those risks. Database systems such as SQLite offer resilience and consistency through a feature known as transaction which builds upon ACID compliance as a building block of database system architecture. The first part of ACID is Atomicity. This guarantees the ability to combine statements into a single group, a transaction in this case, that either fails or succeeds as a whole. If any part of that group of operations fails, they all fail. Another component is Consistency. Whether a transaction fails or not, the database must be left in a consistent state. So if you have some constraints in place and a transaction fails, those constraints must still hold. The I is Isolation. If multiple transactions are happening at once,…

Contents