2020 DBMS Mid
2020 DBMS Mid
DBMS/CS-2004/B Tech (CSE, IT, CSCE, CSSE & ECS)/4 Semester/ 2020
II. Each lecturer, with a lect_id, lect_name, email, and contact_no, is assigned with a
cabin, with cabin_no, floor. However, a cabin can be allotted to 2 lecturers on
sharing basis.
III. A lecturer can teach only one subject, where the subject has a subject_id,
subject_name, and duration. However, a subject can be taught by many lecturers.
IV. Each lecturer has a salary history which contains amt_credited, credit_date, and
deductions.
V. Each Course consists of many subjects , however one subject can belongs to
multiple courses.
VI. The Lecturers are managing the students.
A. Draw ER diagram for the above scenario.
B. Convert the ER diagram into relational schema
6. Consider a schema with two relations, R(A, B) and S(B, C), where all values [5]
are integers. Make no assumptions about keys. Consider the following three
relational algebra expressions:
Two of the three expressions are equivalent (i.e., produce the same answer on
all databases), while one of them can produce a different answer. Which
query can produce a different answer? Give the simplest database instance
you can think of where a different answer is produced.