Font size
WorksheetsDatabase Transactions and Concurrency Control
Total questions: 55
Worksheet time: 55mins
What is a transaction in a database?
A collection of operations that form a single logical unit of work
A request to read or write data in a database
A constraint specified in the database schema
A log used to track database updates
Which of the following is an example of a transaction?
Writing a new customer's invoice
Updating the sales in a database
Reducing the quantity of on-hand products in inventory
All of the above
What is a database request equivalent to in an application program or transaction?
A single SQL statement
A collection of SQL statements
A database update
A database query
What is a database consistent state?
A state where all data is up-to-date
A state where all data is accurate
A state that satisfies the constraints specified in the schema
A state that allows concurrent transactions
What is the purpose of a transaction log in a DBMS?
To keep track of all the transactions that update the database
To store the database schema
To ensure data consistency
To prevent deadlock
Which property of transactions ensures that all operations of a transaction are completed?
Atomicity
Consistency
Isolation
Durability
What does the consistency property of transactions ensure?
Only valid data following all rules and constraints will be written in the database
Data used during the execution of a transaction cannot be used by another transaction
Once transaction changes are done and committed, they cannot be undone or lost
All operations of a transaction should be completed
What does the isolation property of transactions ensure?
All operations of a transaction should be completed
Only valid data following all rules and constraints will be written in the database
Data used during the execution of a transaction cannot be used by another transaction
Once transaction changes are done and committed, they cannot be undone or lost
What does the durability property of transactions ensure?
All operations of a transaction should be completed
Only valid data following all rules and constraints will be written in the database
Data used during the execution of a transaction cannot be used by another transaction
Once transaction changes are done and committed, they cannot be undone or lost
What is a dirty read in transaction isolation levels?
When a transaction reads data that is not committed yet
When a transaction reads inconsistent data
When a transaction reads data that has been modified by another transaction
When a transaction reads additional rows that satisfy a query
What is a non-repeatable read in transaction isolation levels?
When a transaction reads data that is not committed yet
When a transaction reads inconsistent data
When a transaction reads data that has been modified by another transaction
When a transaction reads additional rows that satisfy a query
What is a phantom read in transaction isolation levels?
When a transaction reads data that is not committed yet
When a transaction reads inconsistent data
When a transaction reads data that has been modified by another transaction
When a transaction reads additional rows that satisfy a query
Which isolation level allows dirty reads?
READ UNCOMMITTED
READ COMMITTED
REPEATABLE READ
SERIALIZABLE
Which isolation level prevents dirty reads and non-repeatable reads?
READ UNCOMMITTED
READ COMMITTED
REPEATABLE READ
SERIALIZABLE
Which isolation level prevents dirty reads, non-repeatable reads, and phantom reads?
READ UNCOMMITTED
READ COMMITTED
REPEATABLE READ
SERIALIZABLE
A (a) is a collection of operations that form a single logical unit of work.
In a database, a transaction may consist of several operations, such as writing a new customer's invoice, reducing the quantity of on-hand products in inventory, and updating the sales. If one operation is not successful, all other operations will be (a) .
A database request is equivalent to a single (a) statement in an application program or transaction.
The database consistent state satisfies the constraints specified in the (a) .
A transaction log is used by a DBMS to keep track of all the transactions that update the (a) .
(a) requires that all operations of a transaction should be Completed.
(a) ensures that only valid data following all rules and constraints will be written in the Database.
(a) ensures that data used during the execution of a current transaction cannot be used by another transaction until the first one is completed.
(a) ensures that once transaction changes are done and committed, they cannot be undone or lost.
Concurrency control is used to manage interactions among (a) transactions executing simultaneously.
____ ______ occurs when two concurrent transactions are updating the same data element, and one of the updates is lost.
(a)
Uncommitted data occurs when two transactions are executed concurrently, and the first transaction is rolled back after the second transaction has already accessed the (a) data.
(a) retrievals occur when a transaction accesses data before and after one or more other transactions finish working with the same data.
The number of BEGIN TRANSACTION statements that have occurred on the current connection can be retrieved using (a) .
signals that the transaction has ended unsuccessfully, and any changes or effects must be undone.
(a)
A (a) is less restrictive than a table-level lock and allows concurrent transactions to access different rows of the same table.
(a) involves aborting a transaction requesting a new lock when there is a possibility that a deadlock can occur.
(a) marks the beginning of transaction execution.
(a) signals a successful end of the transaction, and any changes executed by the transaction can be safely committed to the database.
_allows a transaction to read data that is not committed yet.
(a)
(a) ensures that no other transactions can modify or delete data that has been read by the current transaction until the current transaction commits.
(a) isolation ensures that data read by a transaction is prevented from being updated or deleted by any other transaction.
(a) is a point in a transaction when you can roll the transaction back to a certain point without rolling back the entire transaction.
In transaction isolation level (a) , transactions can read dirty data.
(a) allows a transaction to read data that is not committed yet.
What is the primary purpose of a data warehouse?
Storing real-time transaction data
Managing day-to-day operations
Enabling business intelligence activities and analytics
Handling data retrieval for transaction processing
What is the "subject-oriented" characteristic of a data warehouse?
It focuses on database design
It emphasizes data integration
It analyzes data about a particular subject or functional area
It stores data from multiple sources in one place
Which characteristic of data warehouses represents the ability to organize data based on time, such as weekly or monthly data updates?
Non-volatile
Integrated
Subject-Oriented
Time-variant
What is the role of Extraction, Transformation, and Loading (ETL) tools in data warehousing?
Managing data access tools
Designing data models
Performing data conversions and transformations
Generating business reports
What is the purpose of metadata in a data warehouse?
It stores data values
It describes the data warehouse and its usage
It contains primary data for analysis
It provides user access to the data
Which tool is used by corporate users to produce corporate reports for analysis and decision-making?
Data mining tools
Application development tools
Query and reporting tools
OLAP tools
What is a data mart in the context of data warehousing?
A small, single-subject data warehouse subset for specific user groups
The primary data warehouse used by all departments
A tool for data integration
A database for real-time transaction data
Which benefit of a data warehouse allows users to analyze different time periods and trends for making future predictions?
Saving time on data retrieval
Consistent information on cross-functional activities
Integration of data sources
Storing a large amount of historical data
What is a star schema in data warehousing?
A data modeling technique used in OLAP
A data-mining tool
A data warehouse access tool
A data integration technique
Which type of OLAP (Online Analytical Processing) works directly with relational databases and stores facts and dimension tables as relations?
Relational OLAP (ROLAP)
Multi-dimensional OLAP (MOLAP)
Business OLAP (BOLAP)
Technical OLAP (TOLAP)
What is the primary purpose of data mining?
Storing massive amounts of data
Managing day-to-day operations
Uncovering hidden trends, patterns, and relationships in data
Creating metadata for data warehouses
In the data mining implementation process, which step involves selecting the appropriate data, cleaning, and integrating data from multiple sources?
Business Understanding
Data Preparation
Data Understanding
Modeling
Which data mining technique is used to identify data that are like each other and understand the differences and similarities between the data?
Classification
Clustering
Regression
Association Rules
What is the "sequential patterns" data mining technique used for?
Identifying data outliers
Discovering hidden correlations
Analyzing historical data for trends
Creating business reports
What is the main characteristic of OLAP tools that differentiates them from OLTP (Online Transaction Processing) systems?
Multi-dimensional data analysis
Data storage
Transaction management
Database administration
