Serializability

SERIALIZABILITY

Serializability is the classical concurrency scheme. It ensures that a schedule for executing concurrent transactions is equivalent to one that executes the transactions serially in some order. It assumes that all accesses to the database are done using read and write operations.

Let’s take a simple example:

Two transactions T1 and T2 want to update the same row. So there are two concurrent sessions running these transactions and we issue the following DML statement in both the transactions:

UPDATE EMPLOYEE SET SALARY=SALARY+10000 WHERE EMPNO=1210;

Here two transactions are running concurrently updation of salary and searching of employee no.


Example of serializable schedule:

What the schedule S says ??

Read A after updation.

Read B before updation






It is reading B after updation.

So its not serializable.

S is not equal to S1.
It is reading B from database before updation.

so its not serializable.

S is not equal to S2.

It is reading A after updation and reading B before updation.

So it is serializable.

S is equal to S3.

Related topics

Professor Jayesh video tutorial

Please use contact page in this website if you find anything incorrect or you want to share more information about the topic discussed above.