What is a transaction? , Database Management System

Assignment Help:

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:


Related Discussions:- What is a transaction?

Relational database, Consider the following relational database: STUDENT (n...

Consider the following relational database: STUDENT (name, student#, class, major) COURSE (course name, course#, credit hours, department) SECTION (section identifier, course#, sem

ER diagrams, explain exhaustively the problems associated with ER diagrams....

explain exhaustively the problems associated with ER diagrams. include illustrations in your answer

What do you understand by acid, What do you understand by ACID? - ACID...

What do you understand by ACID? - ACID (Atomicity Consistency Isolation Durability) is a quality sought after in a reliable database. Here's the relevance of each quality:

What are the storage types, What are the storage types? The storage typ...

What are the storage types? The storage types are: a) Volatile storage b) Nonvolatile storage

Define average seek time, Define average seek time. The average seek ti...

Define average seek time. The average seek time is the average of the seek times, calculated over a sequence of random requests.

Write short notes on extension and intension, Write short notes on extensio...

Write short notes on extension and intension? In any data model, it is significant to distinguish among the description of the database and the database itself the description

Computer, 1. Will you advise that your organization uses open source softwa...

1. Will you advise that your organization uses open source software and why? 2. Why is it important for business managers to have a basic understanding of the software development

Physical database design issues, Physical Database Design Issues The da...

Physical Database Design Issues The database design includes the process of logical design with the use of E-R diagram, normalisation, etc., followed by the physical design.

Heuristics, Benefits of using heuristics

Benefits of using heuristics

Using sql create a view rs for the relations r and s, Using SQL create a vi...

Using SQL create a view RS for the relations R and S. The view consists of the columns A and D renamed as X and Y in that order. Insert a tuple into it. Show the contents of t

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd