What is a transaction? , Database Management System

What is a transaction?

The Transaction is a unit of data processing. For instance, many of the transactions at a bank may be withdrawal or deposit of money; transfer of money from A's account to B's account etc. A transaction would include manipulation of one or more data values in a database. Therefore, it may need reading and writing of database value. For instance, the withdrawal transactions can be written in pseudo code as:

Example:

; Suppose that we are doing this transaction for person

;  whose account number is X.

TRANSACTION WITHDRAWAL (withdrawal_amount)

start transaction

IF X exist then

READ  X.balance

IF   X.balance > withdrawal_amount THEN

 SUBTRACT withdrawal_amount

WRITE X.balance

COMMIT

ELSE

         DISPLAY "TRANSACTION CANNOT BE PROCESSED"

 ELSE DISPLAY "ACCOUNT X DOES NOT EXIST"

End transaction;

Another same example may be transmitting of money from Account no x to account number y. This transaction may be written as:

Posted Date: 3/11/2013 5:18:33 AM | Location : United States







Related Discussions:- What is a transaction? , Assignment Help, Ask Question on What is a transaction? , Get Answer, Expert's Help, What is a transaction? Discussions

Write discussion on What is a transaction?
Your posts are moderated
Related Questions
Explain concept of inheritance with support of suitable example. Inheritance Inheritance is one of milestone of object-oriented programming language as it allows a creati

What is called mirroring? The simplest approach to introducing redundancy is to duplicate each disk. This method is called mirroring or shadowing.

Explain trivial dependency? Functional dependency of the form α ->β. is trivial if α C β. Trivial functional dependencies are satisfied by all the relations.

What is System R? What are its two major subsystems? System R was intended and developed over a period of 1974-79 at IBM San Jose Research Center. It is a prototype and its pur

What is data block? Data Block - In oracle the data blocks are referred to as tablespaces. A tablespace is an fields of disk consisting of one or more disk files. A tablespace

What are the two types of serializability? The two types of serializability is a)      Conflict serializability b)      View serializability

Whta is the advantage of the database management approach? The advantage of the database management approach is data is integrated and can be accessed by multiple programs.

Data Warehousing & Mining 1. What is the concept of knowledge discovery in database? 2. Describe the following types of Multidimensional Data Models. • Stars, Snowflakes and

Explain four causes for failures in data warehouse projects

Describe Parameteric end users? Parametric end users might be given update access, but are commonly not permitted to change the structure of data.