Associative entities are used when you need a relationship to be involved in a relationship.
For example:
For a normal many-to-many relationship between Student
and Course
, we would use just a diamond. However, if we want to associate Enrollment
with Teacher
, we can turn Enrollment
into an associative entity.
Phyiscally, our database looks like this:
Making Enrollment
a ternary relationship in which the Teacher
is an optional role would have much the same meaning (except it would be denormalized, having a nullable role).