BCS403
USNO
FOutth) Semester B.E./B.Tech. Degree Examination, Dec.2024/Jan.2025
CMR Database Management System
Max. Marks: 100
44NEme:3hrs.
Note: 1. Answer any FIVE full questions, choosing ONE ful question from each module.
2. M: Marks, L: Bloom's level, C: Course outcomes.
Module-1 M L C
Q.1 Define the following terms: 05 L1 Co1
() Database (ii) Schema (üi) Entity
(iv) DDL (v) Degree of a relationship
b. Brieflyexplain characteristics of database approach. 05 L2 CO1
10 L2 CO1
c. List and explain advantages of using DBMS approach.
OR
05 L1 CO1
Q.2 Define the following terms:
(i) Cardinality (ii) Weak entity (i) Program data independencc
(iv) DML (v) Value sets
b Deseribe three-schema architecture. Why do we need mappings between 05 L2 Co1
schema levels?
C. Explain different types of attributes in ER model with suitable example for 10 L2 CO1
each.
Module -2
0.3 With suitable example, explain the entity integrity and referential integrity 05 L2 C02
constraints. Why each is considered important?
h Discuss equijoin and natural join with suitable example using relational 05 L2 CO2
algebra notation.
C. Given the relational tables: 10 L3 C02
Employee: Department:
EID Name DeplD Salary DeptlD DeptNane
Alice 10 5000 10 HR
2 Bob 20 6000 20 IT
3 Eve 20 6500 30 Sales
Project
PID Project Name DeptID
101 Project Alpha 10
102 Project Beta 20
103 Project Gamma 30
Write relational algebra expression for the following:
() Find the names and salaries of all employees in the '1T' department.
(iü) Find the ID's and names of employees who are in the IT' department
and have a salary greater than 6000.
(ii) Find the ID's and names of employees who are either in the HR'
department or have a salary greater than 6000.
(iv) Find the names of employees who are not in the IT' department
(v) Find the names of' employees along with their department names.
OR
Q.4 Explain any two operations that change the state of relation in a database. 05 L2 C02
Provide suitable examples.
b Discuss the aggregation functions and grouping relational algebra with 05 L2 C02
suitable examples.
Given the relational tables: 10 L3 C02
Student: Projcct:
SID Name PID Project Name
a Alice Alpha
Bob Beta
Carol Gamma
Language: Enrollment:
LID Language Name SID PID
Python
Java
C++ b
Write relational algebra expression for the following:
() Rename the student table to Learner and display it.
(ii) Find the students (learners) who are not enrolled in any project.
(ii) Find the students who are enrolled in all projects.
(iv) Find the students who are not enrolled in any project.
(v) Find the students who are enrolled in both the 'Alpha' and 'Beta'
projects.
Module-3
Q.5 a. Explain Armstrong inference rules. 05 L2 C04
b. What is the nced for normalization? Explain INF, 2NF and 3NF with 05 L2 CO4
examples.
What is functional dependency? Write an algorithm to find minimal cover 10 L3 C04
for set of functional dependencies. Construct minimal cover M for set of
functional dependencies which are: E = {B ’A, D’ A, AB ’ D}
OR
Q.6 a. Explain the types of update anomalies in SQLwith an example. 05 L2 C04
b. Explain types of JBBCdrivers. 05 L2 COS
C. Consider the schema R = ABCD, subjected to FDs F = (A ’B, B ’C), 10 L3 CO4
and the non-binary partition DI = {ACD, AB, BC}. State whether DI is a
lossless decomposition? [give all steps in detail].
Module - 4 CMRIT LIBRARY
Q.7 a. Define transaction. Discuss ACID properties. BANGALORE5 n 05 L2 CO5
b. With a neat diagram, explain transition diagram of a transaction. 05 L2COS
C. Demonstrate working of assertion and triggers in SQL with cxample. 10 L3 COS
OR
Q.8 Explain cursor and its properties in embedded SQL with suitable cxample. 05 L2 COS
b. Determine if the following schedule is serializable and explain your 05 L2 CO5
reasoning:
i) TI:ROX)w(X) T2 : R(X)W(X) TI :COMMIT T2: COMMIT
ii) T1:W(X)R(Y) T2: R(X)W(Y) T1:COMMIT T2:COMMIT
BCS403
Consider the tables below: 10 L3 COS
Sailors (sid: integer, sname: string, rating : integer, age:real)
Boats (bid: integer, bname : string, color : string);
Reserves (sid: integer, bid: integer, day : date)
Write SQL queries for the following:
() Write create table statement for reserves.
(iü) Find all information of sailors who have reserved boat number 101.
(ii) Find the names of sailors who have reserved at least one boat.
(iv) Find the names of sailors who have reserved a red boat.
(v) Find the average age of sailors for cach rating level.
Module -5
Q.9 Explain the CAP theorem. 05 L2 CO6
b. What is NOSQL graph database? Explain Neo4j. 05 L2 CO6
C. Why concurrency control and recovery are needed in DBMS? Demonstrate 10 L3 COS
with suitable examples types of problems that may occur when two simple
transactions run concurrently.
OR
Q.10 a. Explain basic operations CRUD in MongoDB. CMRIT LIBRARY
b. Explain deadlock prevention protocols. BANGALORE- 560 032 05 L2 CO6
05 L2 COS
C. Briefly discuss the two-phase looking techniques fo concurrency control. 10|L3 COS