What is a database transaction? MCQ with Answer and Explanation

What is a database transaction?
A. A query that reads data
B. A backup copy of the database
C. A database schema
D. A logical unit of work that consists of one or more SQL statements
Answer: Option D
Solution (By JKSSB Mock Tests)
A transaction is a sequence of operations performed as a single logical unit, ensuring ACID properties.

Discuss this Question (0)

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

Practice More Database Management System (DBMS) Questions

Question #1
Which SQL component is used to specify a fallback default value for a column when no value is provided during an insert operation?
A. DEFAULT
B. UNIQUE
C. NOT NULL
D. CHECK

Correct Answer: Option A


Explanation:
The DEFAULT constraint assigns a predefined default value to a column when an INSERT statement does not explicitly provide a value for that column.

This question belongs to: Computer Database Management System (DBMS)
Question #2
Which of the following is a valid SQL string function?
A. SUBSTRING
B. All of the above
C. CONCAT
D. REPLACE

Correct Answer: Option B


Explanation:
SUBSTRING, CONCAT, and REPLACE are common string functions in SQL.

This question belongs to: Computer Database Management System (DBMS)
Question #3
Which property of ACID ensures that a transaction is treated as a single unit that either fully succeeds or fully fails?
A. Consistency
B. Durability
C. Atomicity
D. Isolation

Correct Answer: Option C


Explanation:
Atomicity ensures that all operations within a transaction are completed successfully; otherwise, the transaction is aborted and all changes are rolled back.

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