DBMS MakeUP-ST2 Solution 2024-25
DBMS MakeUP-ST2 Solution 2024-25
Q.1: Attempt any SIX questions (Short Answer Type). Each question is of two marks. (2 x 6 = 12 Marks)
Ans: Insertion Anomaly: Issues when adding data with missing details.
Deletion Anomaly: Unintended data loss during deletion.
Update Anomaly: Inconsistent data after updates.
Ans: Functional Dependencies (FDs) link attributes, ensuring uniqueness. They aid in
normalization to reduce redundancy.
Example:
StudentID → Course
Course → Instructor
Ans: Inclusion dependency ensures values in one relation's column are subsets of
values in another column, maintaining referential integrity.
Example: Dept in Employee must exist in Department_id.
Department_id (Dept)
101
102
EmployeeID Dept
1 101
g) Discuss BCNF (Boyce-Codd Normal Form), and how does it differ from
(BKL: K2 Level).
3NF? Provide an example of a table violating BCNF and its decomposition.
(3 x 6 = 18
Q.2: Attempt any THREE questions (Medium Answer Type). Each question is of 6 marks.
Marks)
a) Describe the term MVD in the context of DBMS by giving an example. (BKL: K2
Explain 4NF and 5NF with the example. Level).
Ans: Multivalued Dependency (MVD): MVD: When one attribute determines multiple
values of another attribute.
4th Normal Form (4NF): Definition: Eliminates multivalued dependencies.
Example: Split StudentCourses and StudentHobbies tables to remove redundancy.
5th Normal Form (5NF): Definition: Eliminates join dependencies.
Example: Split Students, CoursesInstructors, and StudentsInstructors tables to
remove redundancy.
b) Discuss the transitive dependencies. Explain with an example any two
(BKL: K2
problems that can arise in the database if transitive dependencies are present
Level).
in the database.
Ans: Transitive Dependencies: Occur when non-prime attributes depend on other non-
prime attributes via a chain of dependencies.
Problems:
Data Redundancy: Duplicate data entries.
Update Anomalies: Inconsistent updates across the database
Ans: A functional dependency (FD) shows how one attribute (determinant) uniquely
determines another (dependent). A canonical cover simplifies FDs while keeping
the same closure.
Steps:
Remove redundant: Eliminate derivable FDs.
Remove partial: Remove FDs with non-candidate key determinants.
Remove transitive: Remove FDs with indirect dependencies.
Single determinant: Ensure one determinant per FD.
Single dependent: Ensure one dependent per FD.
Example: Given FDs:
A→B, B→C, A→C, AB→D, B→E
Canonical cover:
A→B, B→E, AB→D
Ans:
(2 x 6 = 12
Q.3: Attempt any SIX questions (Short Answer Type). Each question is of two marks.
Marks)
Ans: The dirty read problem occurs when one transaction reads a value updated by
another transaction that later fails, leading to uncommitted, incorrect data.
d) Explain the concept of conflict serializability and how it can be tested using
(BKL: K2 Level).
a precedence graph.
Ans: Conflict serializability means a schedule can be reordered to a serial one while
preserving conflict relations. A precedence graph tests this:
1. Nodes represent transactions.
2. Directed edges show conflict relationships.
3. A cycle indicates the schedule isn’t conflict serializable; no cycle means
it is.
Ans: Deadlock occurs when transactions wait on each other. Prevention methods
include:
1. Predeclaration: Lock all items before execution.
2. Graph-based Protocol: Lock items in a set order.
Timestamp schemes:
Wait-Die: Older wait for younger; younger are rolled back.
Wound-Wait: Older force younger to roll back; younger wait.
(3 x 6 = 18
Q.4: Attempt any THREE questions (Medium Answer Type). Each question is of 6 marks.
Marks)
a) Explain a transaction in a database system with the help of diagram. (BKL: K2 Level).
d) Conclude Both Serial and Interleaved Transactions Must Adhere to ACID. (BKL: K4 Level).
Ans: Both serial and interleaved transactions must adhere to ACID properties to ensure
database reliability and consistency:
Atomicity: Transactions must be all-or-nothing, regardless of serial or
interleaved execution.
Consistency: The database must move from one valid state to another
after any transaction.
Isolation: Even interleaved transactions must not interfere with each
other, ensuring results are consistent as if executed serially.
Durability: Committed transactions' changes must be permanent, no
matter the execution order.
This ensures data integrity, regardless of transaction execution type.