E D1071 Pages: 4: Limit Answers To The Required Points. Answer All Questions, Each Carries 3 Marks

Download as pdf or txt
Download as pdf or txt
You are on page 1of 4

E D1071 Pages: 4

Reg No.:_______________ Name:__________________________


APJ ABDUL KALAM TECHNOLOGICAL UNIVERSITY
FOURTH SEMESTER B.TECH DEGREE EXAMINATION, MAY 2019
Course Code: CS208
Course Name: PRINCIPLES OF DATABASE DESIGN (CS, IT)
Max. Marks: 100 Duration: 3 Hours
Limit answers to the required points.
PART A
Answer all questions, each carries 3 marks. Marks

1 Illustrate with an example, the difference between the conceptual data models and the (3)
physical data models.
2 How is weak entity type different from a strong entity type? Give an example. (3)
3 What is entity integrity constraint? Why is it important? (3)
4 Using the following ER diagram, create a relation database. Give your assumptions. (3)

PART B
Answer any two full questions, each carries 9 marks.
5 a) With the help of an example, compare DML and DDL. (4)
b) What are logical data independence and physical data independence? What is the (5)
difference between them? Which of these harder to realize? Why?
6 Design an ER diagram to represent the following scenario: (9)
A company has many employees working on a project. An employee can be part of
one or more projects. Each employee works on a project for certain amount of time.
Assume suitable attributes for entities and relations. Mark the primary key(s) and the
cardinality ratio of the relations.
7 Consider the following relations for a database that keeps track of business trips of
salespersons in a sales office:
SALESPERSON(Ssn, Name, StartYear, DeptNo)

Page 1 of 4
E D1071 Pages: 4

TRIP(Ssn, FromCity, ToCity, DepartureDate, ReturnDate, TripId)


EXPENSE(TripId, AccountNo, Amount)
a) A trip can be charged to one or more accounts. Specify the foreign keys for this (3)
schema, stating any assumptions you make.
b) Write relation algebra expression to get the details of salespersons who have travelled (3)
between Mumbai and Delhi and the travel expense is greater that Rs. 50000.
c) Write relation algebra expression to get the details of salesperson who had incurred (3)
the greatest travel expenses among all travels made.
PART C
Answer all questions, each carries 3 marks.
8 With the help of an example, illustrate the use of SQL TRIGGER. (3)
9 List the basic data types available for defining attributes in SQL? (3)
10 Consider a relation R={A,B,C,D,E,F} and a set of functional dependencies (3)
F={A→BC,C→BD,BF→E,F→D}. Find the closure of A. Is Aa candidate key?
Justify.
11 What are fully functional dependencies and partial functional dependencies? Give an (3)
example to distinguish between these?
PART D
Answer any two full questions, each carries 9 marks.
12 a) Consider the following table MARKS. Why is the table not in 1NF? Reconstruct the (5)
table so that it is in 1NF.
Subject
Roll No. Name Marks
Code Name
42 M001 Maths
1001 Tom 34 C002 Chemistry
37 P003 Physics
21 M001 Maths
1057 Sam 25 C002 Chemistry
34 P003 Physics
45 M001 Maths
1001 Tom 48 C002 Chemistry
44 P003 Physics

b) When does a relational scheme is said to be in 3NF? How is BCNF different from (4)
3NF?
13 a) List aggregate functions of SQL. (3)

Page 2 of 4
E D1071 Pages: 4

b) Given a relation R(A,B,C). Find the minimal cover of the set of functional (3)
dependencies given;
F= {A→BC, B→C, A→B, AB→C}
c) What is the lossless (or nonadditive) join property of decomposition? Why is it (3)
important?
14 Consider the relation R = {A, B, C, D, E, F, G, H} and the setof functional (9)
dependencies F = {A→DE, B→F, AB→C, C→GH, G→H}. What is the key for R?
Decompose R into 2NF andthen 3NF relations.
PART E
Answer any four full questions, each carries 10 marks.
15 a) Suppose that we have an ordered file with 400,000 records stored on a disk with (6)
block size 4,096 bytes. File records are of fixed size and are unspanned,with record
length 200 bytes. How many blocks are needed for the file? Approximately, how
many block accesses are required for a binary search in this file? On an average, how
many block accesses are required for a linear search, if the file is nonordered?
b) Based on question 15.a, give an example to illustrate that indexing can improve the (4)
search time.
16 a) Explain the structure of an internal node and a leaf node in a B+-tree. (5)
b) Illustrate with an example how searching for a record with search key field value is (5)
done using a B+-Tree.
17 Why Concurrency Control Is Needed? What are the different types of problems we (10)
may encounter when two transactions run concurrently? Illustrate each problem with
suitable examples.
18 a) What are the desirable properties of transactions? Explain. (4)
b) “If every transaction in a schedule follows the two-phase lockingprotocol, the (3)
schedule is guaranteed to be serializable”, justify the statement.
c) What are the different types of lock that are commonly used in concurrency control? (3)
19 a) Consider the following tables representing courses taken by instructors in an (10)
institute:
INSTRUCTOR(ID, NAME, DEPT, SALARY)
TEACHES(ID, COURSE-ID, SEMESTER, YEAR)
COURSE(COURSE-ID, TITLE, DEPT, CREDITS)
where, ID and COURSE-ID are foreign keys referring to the primary keys with the

Page 3 of 4
E D1071 Pages: 4

same names. Show an initial query tree for the following query and optimize it using
the rules ofheuristics. Assume that TITLE is a candidate key of COURSE.
SELECT NAME, TITLE, SEMESTERYEAR
FROM INSTRUCTOR, COURSE, TEACHES
WHERE COURSE.COURSE-ID=TEACHES.COURSE-ID AND
TEACHES.ID = INSTRUCTOR.ID AND INSTRUCTOR.DEPT =‘MATHS’
AND TEACHES.DEPT = INSTRUCTOR.DEPT
20 a) Write a short note on Big Data. (4)
b) What is a semantic web technology? How is it relevance? (3)
c) How does RDF support semantic web technology? (3)
****

Page 4 of 4

You might also like