- 2070 Magh
ER diagram: product and components
Short answer
Entities: Product (p_no, desc, cost), Component (c_no, desc, measure). Relationships: Product comprised_of Component (M:N), Component has recursive make (assembly, part) with attribute no.
Draw an ER diagram for the following. [The question text is not printed; the page gives only the label and the solution diagram: Product (p_no, desc, cost) is comprised of Component (c_no, desc, measure) in a many-to-many relationship; Component has a recursive relationship 'make' with attribute no.]
The diagram contains two entities, a many-to-many relationship, and a recursive relationship on Component.
Entities and attributes
- Product (p_no, desc, cost).
- Component (c_no, desc, measure).
Relationships
- comprised_of between Product and Component: M : N. A product is made of many components, and one component can be used in many products.
- make on Component (recursive, unary): a component is made from other components. The relationship has the attribute no (how many units of the sub-component are used). Roles: assembly and part.
ER diagram
(p_no)(desc)(cost)
\ | /
[ Product ]
|
M
<comprised_of>
|
N
[Component]----(c_no)
| | | \
| | | (desc)(measure)
| | +---------+
| | |
1 +----<make>---+ (no)
(assembly) N (part)
The recursive line leaves Component and returns to it, labelled with the roles. In the relational schema this becomes: Product(p_no, desc, cost), Component(c_no, desc, measure), Comprised_of(p_no, c_no), Make(assembly_c_no, part_c_no, no).
✓ Answer checked by Claude Opus 5.5 (high effort)
Related questions
- ER diagram: hospital management · Database Management System, chapter 2
- ER diagram: cricket tournament · Database Management System, chapter 2
- ER diagram: employee, skill, machine · Database Management System, chapter 2
- Rural area 22000 L/day river supply (question text cut) · Water Supply Engineering, chapter 7
- Why n-type has many conduction electrons · Electrical Engineering Material, chapter 6
- One-to-many relationship using collections · Object Oriented Analysis and Design, chapter 4
- Components that make up the Web · Web Technology, chapter 2