BCA 4th Semester

Database Management System 2021 Board Question Paper

tribhuvan university logo

Tribhuvan university

Bachelor In Computer Application

Course Title: Database Management System

Code No:CACS 255

Semester:IV

2021

Full Marks:60 Pass Marks:24 Time:3 hours

Candidates are required to answer the question in their own words as far as possible.

Group B
Attempt any SIX question.
[6x5=30]
11.

What is database? Discuss the importance of DBMS.

12.

Define union compatibility. Given following relations, show the resulting relation of Director ∩ Actor and Actor ∪ Director?

Director

FnameLname
DeepakGiri
BhuwanKC
DipendraKhanel

Actor

First nameLast name
DeepakGiri
RajeshHamal
DipendraKhanel

13.

How Order By and Group BY Having Clause in SQL are different? Illustrate with suitable examples.

14.

Why normalization is needed? When any relation is said to be in 1NF and 2NF?

15.

How cost of query is measured during query processing? Construct query expression tree for the relational algebra query:
TLFName LName, Address(ODName="Research" ∧ Department Dnumber=Dno (Employee * Works_on))

16.

How wait-for-graph is constructed? How can you use it to detect deadlock in a schedule of transactions? Support your answer with an example.

17.

How read and write operations are performed in a transaction? List the various states where transactions can enter into.

Group C

Attempt any TWO questions

[2x10=20]
18.

Given the schema as below, write relational algebra and SQL queries for following:
Sailors(sid, sname, rating, age)
Boats(bid, bname, colour)
Reserves(sid, bid, reservedate)
a) Find name, rating and age of all the sailors.
b) Find the name and color of boats having color blue.
c) Find name of the boats reserved on date 2021/07/20.
d) Find the names of boats and sailors who have reserved boats having color green.
e) Use Left and Right Outer Join between Sailors and Reserves.

19.

a) Design an ER diagram of your choice. The ER diagram should contain at least five entities. Out of those entities, one should be weak entity. Your entities should have appropriate attributes including primary key attributes, if any. There should be presence of one to one relationship, one to many relationship and many to many relationships in your ER diagram.
b) Convert the ER diagram in Q. 19. a. into equivalent relational tables.

20.

Define stored procedures and triggers. How they are applicable in database? Illustrate with examples, how can you create before and after triggers on INSERT query.