Tuesday, 25 February 2014

Timestamp and its protocol |Concurrency Control


TIMESTAMP BASED PROTOCOLS- This protocol require that we must have prior knowledge about the order in which the transaction will be accessed.In order to ordering the transaction, we associate a unique fixed timestamp ,denoted by TS(Ti) to each transaction like Ti.This time stamp is assigned by the database system before the transaction Ti starts execution.If a transaction Ti has been...

Introduction to Database management system | Database management system


DATABASE A database is a collection of related data.By data we mean known facts that can be recorded and that have implicit meaning.                EG. Consider the names,tel-phone numbers and address of the people you know. you may have recorded this data in an indexed address book or you may have stored it on a hard drive,using a personal computer and...

File system Versus DBMS |Introduction to Database management system


FILE SYSTEMS VERSUS A DBMS- FILE SYSTEM Also known as traditional file processing system.File processing systems was an early attempt to computerize the manual filing system that we are all familiar with. A file system is a method for storing and organizing computer files and the data they contain...

Data Independence |Introduction to Database management system


DEFINITION- Data independence means upper layers are unaffected by any change in the lower layers. TYPES OF DATA INDEPENDENCE- There are 2 types of data independence. 1. LOGICAL DATA INDEPENDENCE 2. PHYSICAL DATA INDEPENDENCE 1. LOGICAL DATA INDEPENDENCE- If conceptual...

Architecture of database System | Introduction to Database management system


DATABASE SYSTEM ARCHITECTURE Three layers of architecture of DBMS:- 1. External level/View level 2. Conceptual level/Logical level 3. Internal level/Physical level 1. External level/View level-It is the user view and it shows the data that is relevant to the user. It deals with the way in which...

Role of Database management system Database management system


PROCEDURE OF DATABASE ACCESS- Any access to the stored data is done by the data manager. Data manager sends request for a specific physical record to the file manager. Then the file manager decides which physical block of secondary storage devices contains the required record and sends the request...

Advantage of Database management system | Introduction to database management


ADVANTAGES OF A DBMS- 1.) Data independence- Application programs should be as independent as possible from details of data representation and storage. The DBMS can provide an abstract view of the data to insulate application code from such details. 2.) Efficient data access- A DBMS utilizes a variety of sophisticated techniques to store and retrieve data efficiently. This feature is especially...

Monday, 17 February 2014

Two phase locking protocol in concurrency control | Transaction management


TWO PHASE LOCKING PROTOCOL(PESSIMISTIC APPROACH) A transaction follows the two phase locking protocol, if all the locking operations precede the first unlock operation in the transaction. There are two phases in the Schedule. These are: 1.) GROWING PHASE- During which all the locks are requested. 2.) SHRINKING PHASE- During which all the locks are released. Initially a transaction is in the growing...

Concurrency Control algorithm in transaction management |Database management system


CONCURRENT CONTROL ALGORITHMS- There are two approaches used in algorithms to deals with the problems of concurrency control.These are:- 1.) Pessimistic Approach 2.) Optimistic Approach 1.) PESSIMISTIC APPROACH- This approach causes transaction to be delayed in case they conflict with each other at the some time in future. PESSIMISTIC EXECUTION- The validate operation is performed first,if...

Thursday, 13 February 2014

Lock in transaction management | concurrency control


WHAT IS LOCK? A lock is a variable associated with a data item that describes the status of the item with respect to possible operations that can be applied to it.Generally,there is one lock for each data item in the database.Locks are used as a means of synchronizing the access by concurrent transactions to the database items. WHY WE NEED LOCKING TECHNIQUES? When the transactions are running...

Tuesday, 11 February 2014

Concurrency Control in transaction management | Database management


CONCURRENT EXECUTION- Transaction processing systems usually allow multiple transactions to run concurrently.By allowing multiple transactions to run concurrently will improve the performance of the system in terms of increased throughput or improved response time but this allows causes several complications with consistency of the data. EXAMPLE-To illustrate the concept of concurrency control,...

Scheduling of transaction | Transaction Management


SCHEDULING OF TRANSACTIONS Scheduling of transaction represents the actual execution sequence. A schedule of a system is an abstract model to describe execution of transactions running in the system. A Schedule is a list of actions (reading, writing, aborting or committing) from a set of transaction must consist of all instructions of those transactions and must preserve the order in which the...

Monday, 10 February 2014

States of Transaction | Transaction Management and Their states


STATES OF TRANSACTION A transaction must be in one of the following states. 1. Active-The initial state, the transaction stays in this state while it is executing. 2. Partially committed- After the final statement has been executed. 3. Failed-when the normal execution can no longer proceed. 4....

Sunday, 9 February 2014

Transaction and their properties | Transaction management


WHAT IS TRANSACTION? A Transaction is a set of changes that must all be made together.It is a collection of Operations that form a single logical  unit of work.It must be either completed or entirely aborted to ensure the consistency and integrity of database.For Example - A transfer of money from one bank account to another requires two changes to the database both must succeed or fail...