What is a database lock? MCQ with Answer and Explanation

What is a database lock?
A. A user account
B. A mechanism to prevent simultaneous access to the same data causing inconsistency
C. A backup file
D. A type of index
Answer: Option B
Solution (By JKSSB Mock Tests)
Locking is a concurrency control mechanism that ensures data integrity during simultaneous transactions.

Discuss this Question (0)

No comments yet. Be the first to start the discussion!

Practice More Database Management System (DBMS) Questions

Question #1
A key that consists of more than one attribute to uniquely identify rows in a table is called a what?
A. Foreign Key
B. Primary Key
C. Secondary Key
D. Composite Key

Correct Answer: Option D


Explanation:
When a primary key or unique key comprises two or more columns (attributes) combined together, it is known as a Composite Key.

This question belongs to: Computer Database Management System (DBMS)
Question #2
What is a database instance?
A. The schema definition
B. A backup
C. A query result
D. The state of a database at a particular moment in time

Correct Answer: Option D


Explanation:
A database instance refers to the data stored in the database at a specific time, as opposed to the schema (structure).

This question belongs to: Computer Database Management System (DBMS)
Question #3
What is the purpose of the SQL 'GROUP BY' clause?
A. To filter rows
B. To sort the result set
C. To join tables
D. To group rows that have the same values in specified columns into summary rows

Correct Answer: Option D


Explanation:
GROUP BY organizes data into groups based on the values of one or more columns, often used with aggregate functions.

This question belongs to: Computer Database Management System (DBMS)