If these steps weren't "atomic," a technical glitch (like a power outage or server crash) occurring exactly between step one and step two could lead to a disaster. Your money would vanish from your account, but it would never arrive in your friend's account. The money would simply disappear into the digital void. How Atomicity Saves the Day
Imagine you are sending money to a friend to pay for dinner. This seemingly simple action actually requires two distinct steps within the bank's database: the amount from your account balance. Adding that same amount to your friend’s account balance. The Story of a Failed Transaction atonicity
Ensuring atomicity for database transactions (ACID properties) If these steps weren't "atomic," a technical glitch
If anything goes wrong at any point, the system performs a rollback . It undoes any partial changes, returning your account balance to exactly what it was before you hit "send". How Atomicity Saves the Day Imagine you are
To prevent this, systems use . In this "all-or-nothing" approach, the database treats the two steps as one:
Нажимая «Принять» или продолжая пользоваться сайтом, Вы соглашаетесь на использование нами файлов cookie и метрических программ в соответствии с Политикой обработки персональных данных.