Click below for Step by Step and Interview Q & A (dotnetinter) wrote,
Click below for Step by Step and Interview Q & A
dotnetinter

What are ACID Properties( .NET Interview questions with answers)?

ACID are set of properties that guarantee that database transactions are processed reliably.
Let’s talk about every property in detail

1) Atomicity
It says, Database transaction should complete 100% or zero. Example – let’s say there is a transaction which has two steps. Let say one of them complete and power will fail. It is must that even step 1 should rollback or else it is said that Atomicity is violated.

2) Consistency
This property ensures that database transaction will bring database from one valid state to another.
It means only valid data will be written to database. Valid data means which won’t violate any constraints and business rules.


3) Isolation
Every Transaction should be independent of each of other.
It means if two transactions are trying to access the same data and are trying to execute at the same time then one should wait until other ends or else it said that Database is violating Isolation.

4) Durability
Changes need to persist permanently once transaction is termed as successful.
Let say a transaction has 2 steps to complete and both of them executes and completes. Now it time to commit changes to real database. Let say even after success, final commit it not made and waiting for something else to happen (like waiting for memory to get cleaned) and in the meantime power fails. It will make us lost all the changes. Thus we say transaction was not durable. To make it durable we should commit it as soon as we realize that it completes.

How will you make sure that Sql transactions obey ACID properties?
For that transactional statements are there in sql like Begin Transaction, Commit Transaction and Rollback Transaction.

We are thankful to questpond.com to provide this ACID .NET Interview question with answers.
Tags: .net and c# training, .net interview questions with answers, acid properties, csharp interview questions, information technology questions, programming interview questions
Subscribe

  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments