1.

When an entity instance must be a member of only one sub-type, it is which of the following?(a) Disjoint with total specialization(b) Disjoint with partial specialization(c) Overlap with total specialization(d) Overlap with partial specializationThis question was addressed to me during an online interview.This intriguing question originated from The Atomic Data Models and Business Models in section Planning Oracle Applications of Oracle

Answer» <html><body><p>The correct option is (a) Disjoint with <a href="https://interviewquestions.tuteehub.com/tag/total-711110" style="font-weight:bold;" target="_blank" title="Click to know more about TOTAL">TOTAL</a> specialization<br/><br/>The explanation is: GradStudent (_id_, <a href="https://interviewquestions.tuteehub.com/tag/name-573193" style="font-weight:bold;" target="_blank" title="Click to know more about NAME">NAME</a>, gradStuff) UndergradStudent (_id_, name, underGradStuff) Professor (_id_, name) <a href="https://interviewquestions.tuteehub.com/tag/teaches-1240036" style="font-weight:bold;" target="_blank" title="Click to know more about TEACHES">TEACHES</a>(_prof_id_, _stud_id_)<br/><br/>Considering that the relational database above is meant to represent total disjoint specialization, i.e. there is no table Student but rather two completely separate ones, when writing this in SQL in <a href="https://interviewquestions.tuteehub.com/tag/order-1138220" style="font-weight:bold;" target="_blank" title="Click to know more about ORDER">ORDER</a> to implement the database, how would I fetch the student id for the Teaches table? I cannot figure out how to <a href="https://interviewquestions.tuteehub.com/tag/make-546668" style="font-weight:bold;" target="_blank" title="Click to know more about MAKE">MAKE</a> a foreign key from two different tables.</p></body></html>


Discussion

No Comment Found

Related InterviewSolutions