Académique Documents
Professionnel Documents
Culture Documents
Guinto
BSIT-3D
1. Explain the following statement: a transaction is a logical unit of work.
- A transaction is a sequence of logically related commands that accomplish one task and transform the
database from one consistent state into another.
Atomicity
A transaction must be an atomic unit of work; either all of its data modifications are performed, or none
of them is performed.
Consistency
When completed, a transaction must leave all data in a consistent state. In a relational database, all rules
must be applied to the transaction's modifications to maintain all data integrity. All internal data
structures, such as B-tree indexes or doubly-linked lists, must be correct at the end of the transaction.
Isolation
Modifications made by concurrent transactions must be isolated from the modifications made by any
other concurrent transactions. A transaction either recognizes data in the state it was in before another
concurrent transaction modified it, or it recognizes the data after the second transaction has completed,
but it does not recognize an intermediate state. This is referred to as serializability because it results in
the ability to reload the starting data and replay a series of transactions to end up with the data in the
same state it was in after the original transactions were performed.
Durability
After a transaction has completed, its effects are permanently in place in the system. The modifications
persist even in the event of a system failure.
6. What is a scheduler, what does it do, and why is its activity important to concurrency control?
- DBMS_SCHEDULER is a more sophisticated job scheduler introduced in Oracle 10g. The older job
scheduler, DBMS JOB, is still available, is easier to use in simple cases and fit some needs that
DBMS_SCHEDULER does not satisfy.
12. What is a deadlock, and how can it be avoided? Discuss several strategies for dealing with deadlocks.
Deadlocks - A set of processes is deadlocked if each process in the set is waiting for an event that only
another process in the set.
13. What are some disadvantages of time-stamping methods for concurrency control?
14. Why might it take a long time to complete transactions when an optimistic approach to concurrency
control is used?