Entity Relationship diagram - Composition
Posted
by GigaPr
on Stack Overflow
See other posts from Stack Overflow
or by GigaPr
Published on 2010-04-11T22:23:22Z
Indexed on
2010/04/11
22:43 UTC
Read the original article
Hit count: 546
uml
|student-question
Hi,
I am implementing a small database(university Project) and i am facing the following problem.
I created a class diagram where i have a class
Train {Id, Name, Details}
And a class
RollingStock
which is than generalized in Locomotive and FreightWagon.
A train is Composed by multiple RollingStock at a certain time(on different days the rolling
stock will compose a different train).
I represented the relationship train - rolling stock as a diamond filled (UML) but still I
have a many to many relationship between the two tables.
so i guess i have to create an additional table to solve the many to many relationship
train_RollingStock.
but how do i represent the Composition?
Can i still use the filled diamond? If yes on which side?
Thanks
© Stack Overflow or respective owner