Transaction Processing
Transaction Processing
The concept of transaction provides a mechanism for describing logical units of database processing. Transaction processing systems are systems with large databases and hundreds of concurrent users that are executing database transactions. Examples of such systems include systems for reservations, banking, credit card processing, stock markets, supermarket checkout, and other similar systems. They require high availability and fast response time for hundreds of concurrent users.
Definition of Transaction A transaction is a logical unit of database processing that includes one or more database access operationsthese can include insertion, deletion, modification, or retrieval operations. The database operations that form a transaction can either be embedded within an application program or they can be specified interactively via a high-level query language such as SQL. One way of specifying the transaction boundaries is by specifying explicit begin transaction and end transaction statements in an application program; in this case, all database access operations between the two are considered as forming one transaction. A single application program may contain more than one transaction if it contains several transaction boundaries. If the database operations in a transaction do not update the database but only retrieve data, the transaction is called a read-only transaction. Single User versus Multi-user Systems: A DBMS is single user if at most one user at a time can use the system and its a multi-user if many users can use the system and they can access the database concurrently. Single users are restricted to some microcomputer and other dbms are multi user. For example, an airlines reservation system is used by hundreds of travel agents and reservation clerks concurrently. Database systems used in banks, insurance agencies, stock exchanges, supermarkets, and many other applications are multi user systems. In these systems, hundreds or thousands of users are typically operating on the database by submitting transactions concurrently to the system. Multiple users can access databasesand use computer systemssimultaneously because of the concept of multiprogramming, which allows the operating system of the computer to execute multiple programsor processesat the same time. A
single central processing unit (CPU) can only execute at most one process at a time.