CSC265 · TU past paper
Database Management System 2078 question paper
The complete TU 2078 exam paper for Database Management System (CSC265), all 12 questions with solved model answers written to the mark scheme.
Tap a question to open its answer.
- Q1.10 marksActors on the SceneHideAnswer
What are different types of Database users and their roles? Explain the Data independence with example.[10]
- Q2.10 marksER Diagrams, Naming Conventions, and DesigHideAnswer
What are the components of ER diagram? Explain the function of various symbols use in ER diagram. Construct an ER diagram to store data in a library of your college.[10]
- Q3.10 marksTimestamp OrderingHideAnswer
Explain deadlock and starvation. Explain Time stamp based protocol for concurrency control?[10]
- Q4.5 marksThree-Schema Architecture and Data IndepenHideAnswer
What is difference between logical data independence and physical data independence? [5]
- Q5.5 marksRelationship Types, Relationship Sets, RolHideAnswer
Explain Relationship and Relationship sets with example. [5]
- Q6.5 marksBasic Retrieval QueriesHideAnswer
Retirve the TName, SName, SPhone for “ABC” school using SQL from given relation as below. [5]
- Q7.5 marksRelational Model Constraints and RelationaHideAnswer
What is integrity? Explain different types of database integrity. [5]
- Q8.5 marksFunctional DependenciesHideAnswer
Define Functional dependencies. Explain trivial and non trivial dependencies? [5]
- Q9.5 marksBinary Relational OperationsHideAnswer
Explain the difference between 'Join' and 'Natural Join' of algebraic operations with example. [5]
- Q10.5 marksRecovery ConceptsHideAnswer
What is Checkpoints in database recovery? How does it help in database recovery? Explain. [5]
- Q11.5 marksCharacterizing Schedules Based on SerializHideAnswer
Define schedule and serializability. How can you test the serializability? [5]
Schedule and Serializability
Schedule
A schedule (also called a history) is an ordering of the operations from a set of concurrent transactions, where the operations of each individual transaction appear in the same order as they do in that transaction. A schedule defines the interleaved execution sequence of operations (read, write, commit, abort) from multiple transactions.
Types of Schedules:
- Serial Schedule: Transactions execute one after another with no interleaving. If there are n transactions, there are n! possible serial schedules.
- Non-Serial (Concurrent) Schedule: Operations from multiple transactions are interleaved.
Serializability
A concurrent schedule is said to be serializable if its final result (effect on the database) is totally the same as the final result produced by some serial schedule of the same transactions. In other words, even though transactions execute concurrently with interleaved operations, the outcome must be equivalent to some sequential (serial) execution.
Serializability ensures correctness of concurrent execution while maximizing resource utilization and efficiency.
Types of Serializability
-
Conflict Serializability: A schedule is conflict serializable if it can be transformed into a serial schedule by swapping non-conflicting operations.
-
View Serializability: A schedule is view serializable if its view equals that of a serial schedule (no overlapping transactions). Every conflict serializable schedule is view serializable, but if a schedule contains blind writes, it may be view serializable without being conflict serializable.
Testing for Serializability (Precedence Graph Method)
The standard method to test conflict serializability uses a Precedence Graph (also called a Serialization Graph):
Algorithm:
-
Consider only
read_Item(X)andwrite_Item(X)operations from the schedule. -
Construct a Precedence Graph:
- Nodes represent each transaction T1, T2, ..., Tn.
- A directed edge is drawn from Ti → Tj if an operation in Ti appears before a conflicting operation in Tj.
-
Conflicting operations occur when:
- Two transactions access the same data item X, AND
- At least one of them is a write operation.
- Cases: read(X) then write(X), write(X) then read(X), write(X) then write(X).
-
Check for cycles:
- If the precedence graph has no cycle → the schedule is conflict serializable.
- If the precedence graph has a cycle → the schedule is NOT serializable.
Example:
Step T1 T2 1 read(X) 2 read(X) 3 write(X) 4 write(X) - T1 writes X before T2 writes X → edge T1 → T2
- T1 reads X before T2 writes X → edge T1 → T2
- T2 reads X before T1 writes X → edge T2 → T1
This creates a cycle (T1 → T2 → T1), so the schedule is NOT serializable.
Summary: Serializability is the key correctness criterion for concurrent transaction execution in DBMS. The precedence graph (no cycle = serializable) is the standard test for conflict serializability.
- Q12.5 marksBoyce-Codd Normal FormHideAnswer
Define Boyce-Codd normal form with example. How it is different that 3rd Normal form. [5]