What is transaction management?

5 April 2024

Authors

Josh Schneider

Senior Writer, IBM Blog

Ian Smalley

Senior Editorial Strategist

What is transaction management?

Transaction management is an integral process of database management systems (DBMS) during which transaction management software oversees, coordinates and executes any given attempted transaction.

Transaction management software for workflow automation is a critical part of any industry that involves transaction processing, including ecommerce, finance, hospitality and any business that requires accurate database management.

Critically, transaction management software relies on the concept of atomicity to define a singular transaction as a set series of operations that must all be completed, or none are considered to be completed. In other words, to maintain data consistency, a transaction management system ensures that a transaction can never be partially completed.

For example, when a person attempts to withdraw money from an ATM, transaction management software processes the necessary database queries and changes in order to check their account balance, subtract the requested amount, update the bank’s records and release the dispensed cash. All of these steps are considered one new transaction, and the transaction management system ensures that the entire process is completed to prevent any inconsistencies in the bank’s database and preserve an accurate ledger.

During a transaction, the state of the correlating database is in flux and considered to be inconsistent. During this time, a transaction may perform any number of read and/or write operations by either reading the database to provide information (such as checking a bank account balance) and/or writing new information to the database (such as updating an account balance after a withdrawal). Only once the transaction is fully completed can the database return to a new consistent state.

3D design of balls rolling on a track

The latest AI News + Insights 


Discover expertly curated insights and news on AI, cloud and more in the weekly Think Newsletter. 

States of transactions

The principle of atomicity allows transaction management software to treat discrete series of operations as singular transactions while protecting the integrity of the database.

Atomicity prevents errors that could arise from incomplete or interrupted transactions. Returning to the ATM example, atomicity prevents a transaction from debiting money from a user's bank account before dispensing the actual cash. Should something like a system crash prevent the ATM from being able to dispense the money, the entire transaction would be aborted, and no changes would be made to the database or the user’s account.

While the transaction is in progress, and the database is in flux, the transaction can be broken down into a number of sequential transaction states.

Active

Once a transaction begins, it enters into an active state during which database read and write operations can occur.

Partially committed

Once all the necessary steps of a transaction are completed, the transaction is considered to be only partially committed until the master database is updated.

Committed

After a transaction is completed successfully, it is committed to the database, entering a committed state.

Failed

When a transaction fails to execute one or more of its operations or is aborted, it is considered to be in a failed state. A failed transaction will trigger a rollback, which undoes any database changes in progress.

Terminated

The final state for all transactions, a transaction in the terminated state is taken out of the system and can no longer perform any database operations.

All transactions begin in an active state, and if there are no issues, they progress to partially committed, committed and then terminated states. Should an issue arise during the processing of the transaction, the transaction will enter the failed state and rollback any and all changes made during the course of the transaction. The transaction may then reattempt to execute, or abort. Whether aborted or committed, all committed transactions eventually enter a terminated state, freeing up resources for the DBMS to process new transactions.

Understanding ACID Properties

In the field of database management, atomicity is just one of four crucial properties necessary for maintaining database integrity. Referred to by the acronym ACID, the four properties are atomicity, consistency, isolation and durability:

  • Atomicity: Transactions are treated as single units of operation that can either execute entirely or do not execute at all, with no in-between states ever being committed to the master database.
  • Consistency: A database must remain in a consistent state so that any and every user checking the database will have access to the latest, accurate information.
  • Isolation: Transactions must be processed in isolation from each other. When information from a concurrent transaction is relevant to another transaction, transaction isolation levels may be implemented to facilitate proper transaction execution. Common isolation levels include include read uncommitted, read committed, repeatable read and serializable.
  • Durability: Transactions must be durable in the sense that all completed transactions are preserved by the DBMS and won’t be lost in the event of system failure.
AI Academy

The rise of generative AI for business

Learn about the historical rise of generative AI and what it means for business.

Transaction management technologies

As a facet of DBMS, transaction management systems rely on a number of database technologies and software offering various degrees of optimizations, such as automations, templates and checklists. Venders like IBM, Microsoft and Oracle offer a range of transaction management solutions at competitive pricing. Broader transaction management technologies include the following.

Structured Query Language (SQL)

SQL is the standard programming language for storing and processing information in a relational database. Typical SQL commands include BEGIN TRANSACTION, COMMIT and ROLLBACK.

Java Transaction API (JTA)

JTA is the standard application programming interface (API) for enterprise applications, allowing transaction management applications to communicate with other application types, including databases and messaging systems, while ensuring atomicity and consistency.

Transaction management benefits and use cases

Various industries depend on transaction management to effectively and efficiently manage relational databases and the important operational resources they represent—both physical (inventory) and ephemeral (information).

A brief list of common transaction management use cases includes the following.

Finance

Financial services, including brokerage firms and banking institutions, depend on transaction management in not only their day-to-day operations but in their microsecond-to-microsecond business, as well. Without transaction management, common products like modern checking accounts and stock trading platforms wouldn’t be feasible.

Ecommerce

For online retail platforms, transaction management facilitates order processing, payments and inventory management to effectively fulfill ecommerce orders.

Real estate

In the complicated world of real estate, professional transaction coordinators rely on transaction management software to streamline the buying, selling and leasing of properties.

Customer relationship management (CRM)

CRM systems like Salesforce are pivotal for large organizations to track and manage leads, customer interactions, sales orders and a wide range of additional touch points made accessible through DBSM and transaction management.

Transaction management challenges

Transaction management is an essential part of many modern business operations. However, reliable transaction management must be able to mitigate certain critical challenges:

  • Dependency management: Transaction management systems must be equipped to manage transaction dependencies to avoid deadlock situations in which one or more individual transactions are stuck waiting for information to be released from another transaction.
  • System crash recovery: In the event of system failures, transaction management systems need to be durable enough to restore the database to a consistent state.
  • Real-time processing: For real-time dependent transactions, such as stock trading and pricing engines, transaction processing systems must be able to handle large volumes of transactions efficiently and with low latency.
Related solutions
Business operations solutions

Build a more resilient business with AI-powered solutions for intelligent asset management and supply chain.

Explore operations solutions
IBM Blueworks Live

IBM Blueworks Live is SaaS for business process modeling.

Explore Blueworks Live
Business automation solutions

Discover business process automation solutions that deliver intelligent automations quickly with low-code tooling.

Explore automation solutions
Take the next step

Transform your business operations with IBM’s industry-leading solutions. Enhance productivity, agility and innovation through intelligent workflows and automation technologies.

 

Explore operations solutions Explore artificial intelligence services