0

Transactions and Concurrency Control

Description: Transactions and Concurrency Control
Number of Questions: 15
Created by:
Tags: Transactions and Concurrency Control Java/Oracle /C/C++ Database Management System Oracle
Attempted 0/15 Correct 0 Score 0

Which of the following scenarios may leaves the transaction vulnerable to dirty reads, phantom reads etc.. in a database system?

  1. A transaction writes a data item after it is read by an uncommitted transaction.

  2. A transaction reads a data item after it is read by an uncommitted transaction.

  3. A transaction reads a data item after it is written by a committed transaction.

  4. A transaction reads a data item after it is written by an uncommitted transaction.


Correct Option: D
Explanation:

 This may leave the transactions vulnerable to dirty reads, phantom reads, etc. in the database system.

Which one is not a property of a transaction?

  1. Atomicity

  2. Isolation

  3. Durability

  4. Exchanging


Correct Option: D
Explanation:

Exchanging is not a property of a transaction. The ACID properties of a transaction are:

  1. Atomicity
  2. Isolation
  3. Durability
  4. Consistency

In Oracle, commit and savepoint commands come under

  1. Data Definition Language

  2. Data Manipulation Language

  3. Transaction Control Language

  4. Object Oriented Language

  5. Procedure Oriented Language


Correct Option: C
Explanation:

In Oracle, commit and savepoint commands control the transactions specified in the form of queries. Hence, this is the correct option.

In which of the following conditions is a transaction said to be in a committed state?

  1. After the successful execution of the transaction

  2. After the discovery that normal execution can no longer proceed

  3. When it is in its initial state

  4. After the final statement has been executed

  5. After the transaction has been rolled back


Correct Option: A
Explanation:

This option is correct as a transaction is committed only after its successful completion.

Which of the following calls is made in Oracle to perform work at some remote database?

  1. Rollback

  2. Commit

  3. Remote procedure calls

  4. System change number

  5. Savepoint


Correct Option: C
Explanation:

These are the calls made in Oracle to perform work at some remote database.

_________ are Transaction Control Language commands in SQL.

  1. Grant and Commit

  2. Savepoint and Revoke

  3. Grant and Revoke

  4. Commit and Rollback


Correct Option: D

Which of the following phases in commit mechanism is the one in which the coordinator asks all other nodes to commit the transaction?

  1. Prepare phase

  2. Forget phase

  3. Commit phase

  4. Global coordinator

  5. Client


Correct Option: C
Explanation:

This phase in commit mechanism is the one in which the coordinator asks all other nodes to commit the transaction.

When a transaction is executing, it is said to be in _____ state.

  1. active

  2. partially committed

  3. failed

  4. committed

  5. abort


Correct Option: A
Explanation:

This option is correct as the transaction stays in this state while it is executing.

Transaction X holds a shared lock R. What happens if transaction Y requests for a shared lock on R?

  1. Results in deadlock situation

  2. Immediately granted

  3. Immediately rejected

  4. Granted as is released by X


Correct Option: B

The point of synchronization between a database and transaction log file is known as

  1. checkpoint

  2. backup mechanism

  3. shadow paging

  4. cascading rollback

  5. recovery


Correct Option: A
Explanation:

This option is correct as checkpoints are the points scheduled at regular intervals, and involves operations like writing all the records from the main memory to secondary storage. Hence, it synchronizes database and t ransaction log files.

A transaction is said to be in which state, when it can no longer proceed?

  1. Active

  2. Failed

  3. Partially committed

  4. Aborted

  5. Committed


Correct Option: B
Explanation:

This option is correct as the transaction is said to be in this state, when the normal execution can no longer proceed.

A transaction is said to be in which state, when it is rolled back?

  1. Aborted

  2. Active

  3. Partially committed

  4. Failed

  5. Committed


Correct Option: A
Explanation:

This option is correct as when the execution of the transaction is stopped or aborted, it is rolled back to a state prior to its start.

_______ command is used to undo the work done in the current transaction.

  1. Revoke

  2. Rollback

  3. Savepoint

  4. Commit


Correct Option: B

Which of the following is the first step in the 'transaction processing cycle', which captures business data through various modes such as optical scanning or at an electronic commerce website?

  1. Document and report generation

  2. Database maintenance

  3. Transaction processing

  4. Data entry


Correct Option: A
Explanation:

The first step in the ‘transaction processing cycle’ is document and report generation.

Which of the following transactions in distributed databases guarantees that all statements in a transaction either commit or rollback as a unit?

  1. Remote transaction

  2. Distributed transaction

  3. Two-phase commit mechanism

  4. Global database name

  5. None of these


Correct Option: C
Explanation:

This transaction in distributed databases guarantees that all statements in a transaction either commit or rollback as a unit.

- Hide questions