What is a transaction and what are ACID properties?
Answer Posted / pardeep jangra
A transaction is a unit of program execution that
accesses and possibly updates various data items.
! A transaction must see a consistent database.
! During transaction execution the database may be
inconsistent.
! When the transaction is committed, the database must
be consistent.
ACID PROPERTIES
Atomicity- requires that each transaction is "all or
nothing": if one part of the transaction fails, the entire
transaction fails, and the database state is left unchanged.
An atomic system must guarantee atomicity in each and every
situation, including power failures, errors, and crashes.
Consistency
The consistency- property ensures that any transaction will
bring the database from one valid state to another. Any data
written to the database must be valid according to all
defined rules, including but not limited to constraints,
cascades, triggers, and any combination thereof.
Isolation
Isolation- property ensures that the concurrent execution of
transactions results in a system state that could have been
obtained if transactions are executed serially i.e. one
after the other.[citation needed]
Durability
Durability- means that once a transaction has been
committed, it will remain so, even in the event of power
loss, crashes, or errors. In a relational database, for
instance, once a group of SQL statements execute, the
results need to be stored permanently (even if the database
crashes immediately thereafter).
| Is This Answer Correct ? | 1 Yes | 1 No |
Post New Answer View All Answers
How do I debug a stored procedure in sql server?
Which sql server is best?
What is the architecture of ms sql reporting service?
Mention the different authentication modes in sql server.
what is a default tcp/ip socket assigned for sql server? : Sql server database administration
explain different levels of normalization? : Sql server database administration
What is a deadlock and what is a live lock?
What is an index in sql?
Why we should not use triggers?
What is conditional split?
What is index, cluster index and nonclustered index?
What is data mart? : sql server analysis services, ssas
What are secondary xml indexes?
How to connect to a sql server using odbc_connect()?
Is it possible to have clustered index on separate drive from original table location?