Consider the following EER diagram: The EER diagram provides a conceptual model
ID: 3765052 • Letter: C
Question
Consider the following EER diagram:
The EER diagram provides a conceptual model based on the data requirements for a vehicle management application. It shows a specialization that contains a super class and two subclasses. Based on the EER diagram, a relation model should be constructed as the logical design. Generally, there are two ways to design relational tables based on a specialization. One is a single-table approach, while the other uses multiple tables.
You are required to complete the following items.
a. Discuss the pros and cons of the two different approaches (single vs. multiple tables) to mapping a specialization into relational tables.
b. Decide which approach you choose for the specialization in the EER diagram and justify your choice.
c. According to your choice, provide the relational schema which is mapped from the EER diagram. Note that you do not need to provide the domains for the attributes.
Explanation / Answer
Hi,
Below is the solution to your question:
Answer a:
Single table approach:
Pro:
Multiple table approach:
Pro:
Multiple tables help in the following ways / cases:
(a) if different people are going to be developing applications involving different tables, it makes sense to split them.
(b) If you want to give different kind of authorities to different people for different part of the data collection, it may be more convenient to split them. (Of course, you can look at defining views and giving authorization on them appropriately).
(c) For moving data to different places, especially during development, it may make sense to use tables resulting in smaller file sizes.
(d) Smaller foot print may give comfort while you develop applications on specific data collection of a single entity.
(e) It is a possibility: what you thought as a single value data may turn out to be really multiple values in future. e.g. credit limit is a single value field as of now. But tomorrow, you may decide to change the values as (date from, date to, credit value). Split tables might come handy now.
Answer b.
car_LiscencePlateNO VARCHAR(20) not null REFERENCES VEHICLE(LiscencePlateNO),
MaxSpeed VARCHAR(20) not null,
NOOfPassengers VARCHAR(20) not null,
CREATE TABLE Truck(
truck_vehicleID VARCHAR(20) not null REFERENCES VEHICLE(vehicleID),
truck_LiscencePlateNO VARCHAR(20) not null REFERENCES VEHICLE(LiscencePlateNO),
NoofAxies VARCHAR(20) not null,
Tonnage VARCHAR(20) not null,
So for the above metioned EER Diagram its better to use a single table approach.
Answer c:Answered in question b.The relational schema is given above.
Hope that helps...HAPPY ANSWERING!!!!!!!
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.