Dears,, Iwant Answers to these questions: Q1: A. Consider the following relation
ID: 3826341 • Letter: D
Question
Dears,,
Iwant Answers to these questions:
Q1:
A. Consider the following relation R with all functional dependences F and normalize it into 2NF, 3NF, and BCNF.
R= {Patient_No,Patient_Name,App_No,Time,Doctor}
F= { Patient_No à Patient_Name
Patient_No, App_No à Time, Doctor
Time à App_No }
B. Explain why the following relation R is in 3NF but not in BCNF.
R={a,b,c,d}
F= {a,b à c,d
a,d à b}
Q2:
author(author_id, first_name, last_name)
author_pub(author_id, pub_id, author_position)
book(book_id, book_title, month, year, editor)
pub(pub_id, title, book_id)
author_id in author_pub is a foreign key referencing author.
pub_id in author_pub is a foreign key referencing pub
book_id in pub is a foreign key referencing book
editor in book is a foreign key referencing author(author_id)
Primary keys are underlined
1- How many tuples will be returned by the following relational algebra query?
book_title(book)
2- What question does the following expression answer?
author_id (author) – editor(book)
3- Write a relational algebra expression that returns the names of all authors who are book editors.
4- How many tuples are returned by the following relational algebra expression?
author author_id=editor book
Explanation / Answer
a)
DB{Patient_No,Patient_Name,App_No,Time,Doctor}
2NF Eliminate partial key dependencies
DB(Patient_No,Time,Doctor)
R1(Patient_No,Patient_Name)
R2(Time,App_No)
3NF Eliminate transitive dependencies
None: so just as 2NF
BCNF Every determinant is a candidate key
DB(Patient_No,Time,Doctor)
R1(Patient_No,Patient_Name)
R2(Time,App_No)
b)
Go through all determinates where ALL of the left hand attributes are present in a relation and at least ONE of the right hand attributes are also present in the relation.
Patient_No -> Patient_Name
Patient_No is present in DB, but not Patient_Name, so not relevant.
Patient_No,App_No -> Time,Doctor
Not all LHS present, so not relevant.
Time -> App_No
Time is present, and so is App_No, so relevant. This is a candidate key. However, Time is currently the key for R2, so satisfies the rules for BCNF.
BCNF: as 3NF
DB(Patient_No,Time,Doctor)
R1(Patient_No,Patient_Name)
R2(Time,App_No)
As per. Chegg policy we are only authorized to provide answer for 1st question and it sub-parts(max. upto 4). I would request you to kindly re-post the 2nd question. Thanks.
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.