What is OLTP?
OLTP, or online transactional processing, enables the real-time execution of large numbers of database transactions by large numbers of people, typically over the internet.
A database transaction is a change, insertion, deletion, or query of data in a database. OLTP systems (and the database transactions they enable) drive many of the financial transactions we make every day, including online banking and ATM transactions, e-commerce and in-store purchases, and hotel and airline bookings, to name a very few. In each of these cases, the database transaction also remains as a record of the corresponding financial transaction. OLTP can also drive non-financial database exchanges, including password changes and text messages.
In OLTP, the common, defining characteristic of any database transaction is its atomicity (or indivisibility)—a transaction either succeeds as a whole or fails (or is canceled). It cannot remain in a pending or intermediate state.
Characteristics of OLTP systems
In general, OLTP systems do the following:
- Process a large number of relatively simple transactions: Usually insertions, updates, and deletions to data, as well as simple data queries (for example, a balance check at an ATM).
- Enable multi-user access to the same data, while ensuring data integrity: OLTP systems rely on concurrency algorithms to ensure that no two users can change the same data at the same time and that all transactions are carried out in the proper order. This prevents people from using online reservation systems from double-booking the same room and protects holders of jointly held bank accounts from accidental overdrafts.
- Emphasize very rapid processing, with response times measured in milliseconds: The effectiveness of an OLTP system is measured by the total number of transactions that can be carried out per second.
- Provide indexed data sets: These are used for rapid searching, retrieval, and querying.
- Are available 24/7/365: Again, OLTP systems process huge numbers of concurrent transactions, so any data loss or downtime can have significant and costly repercussions. A complete data backup must be available for any moment in time. OLTP systems require frequent regular backups and constant incremental backups.
OLTP vs. OLAP
OLTP is often confused with online analytical processing, or OLAP. Both have similar acronyms and are online data processing systems, but that's where the similarity ends.
OLTP is optimized for executing online database transactions. OLTP systems are designed for use by frontline workers (e.g., cashiers, bank tellers, part desk clerks) or for customer self-service applications (e.g., online banking, e-commerce, travel reservations).
OLAP, on the other hand, is optimized for conducting complex data analysis. OLAP systems are designed for use by data scientists, business analysts, and knowledge workers, and they support business intelligence (BI), data mining, and other decision support applications.
Not surprisingly, there are several distinct technical differences OLTP and OLAP systems:
- OLTP systems use a relational database that can accommodate a large number of concurrent users and frequent queries and updates, while supporting very fast response times. OLAP systems use a multidimensional database—a special kind of database created from multiple relational databases that enables complex queries of involving multiple data facts from current and historical data. (An OLAP database may be organized as a data warehouse.)
- OLTP queries are simple and typically involve just one or a few database records. OLAP queries are complex queries involving large numbers of records.
- OLTP transaction and query response times are lightning-fast; OLAP response times are orders of magnitude slower.
- OLTP systems modify data frequently (this is the nature of transactional processing); OLAP systems do not modify data at all.
- OLTP workloads involve a balance of read and write; OLAP workloads are read-intensive.
- OLTP databases require relatively little storage space; OLAP databases work with enormous data sets and typically have significant storage space requirements.
- OLTP systems require frequent or concurrent backups; OLAP systems can be backed up far less frequently.
It's worth noting OLTP systems often serve as a source of information for OLAP systems. And often, the goal of the analytics performed using OLAP is to improve business strategy and optimize business processes, which can provide a basis for making improvements to the OLTP system.
Examples of OLTP systems
Since the inception of the internet and the e-commerce era, OLTP systems have grown ubiquitous. They’re found in nearly every industry or vertical market and in many consumer-facing systems. Everyday examples of OLTP systems include the following:
- ATM machines (this is the classic, most often-cited example) and online banking applications
- Credit card payment processing (both online and in-store)
- Order entry (retail and back-office)
- Online bookings (ticketing, reservation systems, etc.)
- Record keeping (including health records, inventory control, production scheduling, claims processing, customer service ticketing, and many other applications)
OLTP and IBM Cloud
IBM’s pioneering transaction-oriented application management software quickly became the industry standard during the mainframe era. Today, IBM offers enterprise-class data management solutions that are AI-driven, designed for cloud native architectures and optimized for transactional workloads.
IBM Db2 is a relational, multi-modal database that delivers advanced data management and analytics capabilities for both structured and unstructured data and a broad array of workloads, including OLTP. In essence, Db2 enables enterprises to perform OLAP queries directly on a transactional database that’s optimized for use in production systems, combining the benefits of OLTP and OLAP databases into one high-performing and efficient data store.
IBM Informix is a scalable, embeddable database with self-managing capabilities, optimized for OLTP and Internet of Things (IoT) data. Versatility and ease of use make Informix a preferred solution for a wide range of environments, from enterprise data warehouses to individual application development.
In addition, IBM Cloud Pak for Data enables organizations to integrate data from across their hybrid and multicloud environments into a comprehensive and intelligent platform that modernizes their use of data analytics across the entire organization. This open, extensible, data and AI platform will run anywhere, making data-driven insights available to empower decision-makers and accelerate innovation.
To learn more about how IBM Cloud can provide a foundation for high-performing customer-facing business applications, sign up for a free IBM Cloud account today.