0% found this document useful (0 votes)
22 views3 pages

Database Systems (CSE2224)

This document is a question paper for the Fourth Semester B.Tech Degree Examinations in Database Systems at Manipal Academy of Higher Education, scheduled for May 7, 2024. It includes various questions on relational algebra, database architecture, SQL queries, normalization, and transaction management, with a total of 50 marks and a duration of 180 minutes. The paper covers topics relevant to computer science and engineering, particularly in artificial intelligence, machine learning, and cybersecurity.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
22 views3 pages

Database Systems (CSE2224)

This document is a question paper for the Fourth Semester B.Tech Degree Examinations in Database Systems at Manipal Academy of Higher Education, scheduled for May 7, 2024. It includes various questions on relational algebra, database architecture, SQL queries, normalization, and transaction management, with a total of 50 marks and a duration of 180 minutes. The paper covers topics relevant to computer science and engineering, particularly in artificial intelligence, machine learning, and cybersecurity.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Question Paper

Exam Date & Time: 07-May-2024 (02:30 PM - 05:30 PM)

MANIPAL ACADEMY OF HIGHER EDUCATION


FOURTH SEMESTER [Link]. DEGREE EXAMINATIONS - APRIL / MAY 2024
SUBJECT: CSE 2224/CSE_2224 - DATABASE SYSTEMS
(SPL: COMPUTER SCIENCE AND ENGINEERING - ARTIFICIAL INTELLIGENCE AND MACHINE LEARNING / COMPUTER
SCIENCE / COMPUTER SCIENCE AND ENGINEERING - CYBER SECURITY)
DATABASE SYSTEMS [CSE 2224]
Marks: 50 Duration: 180 mins.

A
Answer all the questions.

1A) Consider the following relations: (5)


lives(person-name, street, city)
works(person-name, company-name, salary)
located-in(company-name, city)
manages(person-name, manager-name)
write the following queries using relational algebra.

1. List the names of all persons who live in 'New York'


2. List the name of persons, working at Infosys and who earn more than
INR 50,000.
3. Find the names of persons who both work for a company and manage another person
4. List the names of persons who neither work for 'Google' nor 'Microsoft
(1+1+1½+1½ = 5 marks)
1B) Consider Manipal Infra Tech is going for Inventory automation in their office. Demonstrate how the (3)
three levels of DBMS architecture can be implemented for the above scenario.
1C) Illustrate any two good reasons for allowing concurrency. (2)
2A) Check whether the given schedule S is conflict serializable or not. If yes, then determine all the (4)
possible serialized schedules.

Page 1 of 3
2B) Suppose you are given the following requirements for a simple database for the National Hockey (3)
League (NHL):

The NHL has many teams,


Each team has a name, a city, a coach, a captain, and a set of players,
Each player belongs to only one team,
Each player has a name, a position (such as left wing or goalie), a skill level, and a set of
injury records,
A team captain is also a player,
A game is played between two teams (referred to as host_team and guest_team) and has a
date (such as May 11th, 1999) and a score (such as 4 to 2).

Construct a clean and concise ER diagram for the NHL database. List your assumptions and clearly
indicate the cardinality mappings as well as any role indicators in your ER diagram.
2C) Consider the following schema for an Airplane Database and write the following queries in SQL: (3)

Flights (fno: integer, from: string, to: string, distance: integer,


Departs: time, arrives: time, price: real)
Aircraft (aid: integer, aname: string, cruisingrange: integer)
Certified (eid: integer, aid: integer)
Employees (eid: integer, ename: string, salary: integer)
Flys(eid:integer,fno:integer)

i) Create a view to find the names of pilots certified for some Boeing aircraft.
ii) For all aircraft with cruising range over 1500 Kms, find the name of the aircraft and the average
salary of all pilots certified for this aircraft.
iii) Find the names of pilots whose salary is less than the price of the cheapest route from
Hyderabad to New York.
3A) A play school wants to manage data about children attending their programs. They need a (4)
database schema and SQL queries to handle various operations efficiently. The schema includes
tables for children, classes, and activities.
Children(ChildID, FirstName, LastName, DateOfBirth, ParentName, ContactNumber)
Classes(ClassID, ClassName, AgeGroup, TeacherName)
Activities(ActivityID, ActivityName, ClassID, ActivityDate, DurationHours)
Write the SQL queries for the following:

i) Retrieve the details of all children in a class "C1".


ii) Fetch the total number of children enrolled in each class
iii) Retrieve the details of children who either do not have any class enrollment or are enrolled in
classes other than the 'Playgroup' class.
3B) i) Consider the relation R(V, W, X, Y, Z) with functional dependencies (4)
F= {Z -> Y, Y -> Z , X -> Y,X -> V, VW -> X}.
Find the closure for attribute X given the functional dependencies above.
ii) Where we can apply attribute closure in Normalization?
3C) Differentiate between WHERE and HAVING Clause in SQL by mentioning at least 4 differences. (2)
4A) Consider a simple checkpointing protocol and the following set of operations in the log. (3)
(start, T4); (write, T4, y, 2, 3); (start, T1); (commit, T4); (write, T1, z, 5, 7);
(checkpoint);
(start, T2); (write, T2, x, 1, 9); (commit, T2); (start, T3); (write, T3, z, 7, 2);
If a crash happens now and the system tries to recover using both undo and redo operations, what
are the contents of the undo list and the redo list?
4B) Consider R(ABCDEF) with FDs, F={ AB->CDE, A->D, B->E, C->BD}. Find key for R. Is R in 3NF? If (4)
not normalize R into 3NF using 3NF Decomposition algorithm
4C) For the following word statement, design the E-R diagram and draw the relations. Use any (3)
reasonable assumptions. "A machine shop produces many parts which it takes on contract. It
employs many machinists who operate any of the machines. A part needs working on only one
machine. A record is kept on the quantity of material needed for producing each part. The
production of each part is tracked by giving a job number, start time and end time and machinist
Page 2 of 3
identification."
5A) Examine how storing records from various relations in a single file enhances the accessibility of (2)
data from a single relation.
5B) Consider transactions T1 and T2. (4)
Transaction T1 displays the contents of accounts A and B.
T1: Read(B) Read(A) Display(A+B)
Transaction T2 transfers Rs50 from account B to account A, and display contain of both.
T2: Read (B) B= B - 50 Write (B) Read (A) A= A+ 50 Write (A) Display (A+B)
Let us assume that timestamp will be assign immediately before its first instruction. Consider
following schedule in which TS(T1) < TS(T2). Design possible schedule under timestamp protocol
and justify the steps.
5C) Construct a B+ tree for the following set of key values: (4)
(1,2,3,4,5,6,7,8,9,10,11,12).
Assume that the tree is initially empty and values are added in ascending order. No. of pointers that
will fit in one node is 4.

-----End-----

Page 3 of 3

You might also like