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

SCHOOL OF INFORMATION TECHNOLOGY AND ENGINEERING

MTech(SE) - Winter Semester - 2019-20


Course Name: Database Management Systems
Course Code: SWE1004

1. Explain the suitable steps of ER-to-Relational mapping algorithm that are used to convert
the strong entity type, multivalued attribute, weak entity type and 1:1 cardinality ratio
relationship with examples.

2. EMPLOYEE ( Ssn, Fname, Lname, Address, Date_of_joining, Sssn, Dno)


DEPARTMENT (Dnum, Dname)
Write a query for the following:
a. Create the above tables with necessary constraints.
b. Retrieve the address of employees whose supervisor is ‘siva’ and working in ‘IT’
c. Display number of employees in CSE department
d. Retrieve the experience of each employee.
e. Display date_of_joining in the format ‘January 22 2018’

3. Notown Records has decided to store information about musicians who perform on its
albums (as well as other company data) in a database.
Each musician that record at Notown has an SSN, a name, an address, and a phone number.
Each instrument used in songs recorded at Notown has a name (eg. Guitar, synthesizer,
flute) and a musical key (eg., C, B-flat, E-flat). Each album recorded on the Notown label
has a title, a copyright date, a format (eg., CD or MC) and an album identifier. Each song
recorded at Notown has a title and an author. Each musician may play several instruments,
and a given instrument may be played by several musicians. Each album has a number of
songs on it, but no song may appear on more than one album. Each song is performed by
one or more musicians, and a musician may perform a number of songs. Each album has
exactly one musician who acts as its producer. A musician may produce several albums, of
course. Draw an ER diagram for the above requirements (Be sure to indicate all key and
participation constraints and any assumptions you make).
4. Faculty (f_code, name, school, cabin )
Courses (c_code, title, credits, school)
Registration ( c_code, f_code, venue, slot)
Write a relational algebra expression for the following:
a. Find the courses (codes) that are scheduled in SJT.
b. Produce a school wise listing of course titles
c. Find the course titles that are offered in A1 slot.
d. Produce a listing of course code, title, faculty code, faculty name for which registration
has been done in SJT113
e. Find the faculty names who are taking software metrics classes in SJT113

5. Consider the universal relation R= {A,B,C,D,E,F} and a set of functional dependencies F= {


{A C,F}, { C  D}, { B E}}. What is the key for R? Decompose R into 2NF, then 3NF
relations.

You might also like