Database & Data Handling (NCCIA) MCQs
1999 MCQs is category mein available hain.
All MCQs in Database & Data Handling (NCCIA)
201 What is meant by ‘commit point’ in a distributed transaction?
Explanation
- In a distributed transaction all participants must agree at the commit point.
- Two-phase commit coordinates this agreement.
Last verified on 27-11-2026
202 Which statement best describes atomicity in terms of COMMIT and ROLLBACK?
Explanation
- Atomicity is enforced by ending a transaction with COMMIT or ROLLBACK as a whole.
- Partial success is not allowed.
Last verified on 27-11-2026
203 What is a compensating transaction?
Explanation
- Because committed work cannot be rolled back, a compensating transaction reverses its effect.
- For example a second transfer returns the money.
Last verified on 27-11-2026
204 Which of the following should be done before COMMIT in a funds transfer?
Explanation
- Validate both updates and constraints before committing.
- Committing a half-checked transfer could make an error permanent.
Last verified on 27-11-2026
205 What does BEGIN TRANSACTION do to autocommit in many systems?
Explanation
- An explicit BEGIN starts a multi-statement transaction and suspends autocommit.
- COMMIT or ROLLBACK ends it and restores autocommit behaviour.
Last verified on 27-11-2026
206 If two savepoints s1 and s2 are created in order, what does ROLLBACK TO SAVEPOINT s1 do to s2?
Explanation
- Rolling back to s1 discards work after s1, including savepoint s2.
- Savepoints created after the target are removed.
Last verified on 27-11-2026
207 Which recovery action uses the transaction log after a crash?
Explanation
- Recovery redoes committed changes and undoes uncommitted ones from the log.
- This restores the database to a consistent state.
Last verified on 27-11-2026
208 If a program crashes before COMMIT, what happens to its uncommitted changes?
Explanation
- Uncommitted changes are not durable and are rolled back on recovery.
- Only committed work survives a crash.
Last verified on 27-11-2026
209 What is the main risk of leaving a transaction open without COMMIT or ROLLBACK?
Explanation
- An open transaction holds locks and may block others and grow the log.
- Commit or roll back promptly.
Last verified on 27-11-2026
210 What is the difference between COMMIT and SAVEPOINT?
Explanation
- COMMIT finalises the whole transaction; a savepoint only marks a point for partial rollback.
- A savepoint does not make anything permanent.
Last verified on 27-11-2026