Difference between ER diagram and Class diagram

class-diagramer-diagram

I have been given a description and need to draw ER diagram and Class diagram for the description.

Now I am having issue with understanding the differences between these 2 diagrams.
When I draw the diagrams entities of ER diagram becomes classes. I am not sure whether I am in right track.

Please explain me what is the difference and similarities of these two?

Best Answer

From DifferenceBetween.com:

ER diagrams represent the abstract representation of the data model, while class diagrams represent the static structure and behavior of the proposed system. Main building blocks of ER diagrams are entities, relationships and attributes but the main building blocks of class diagrams are classes, relationships and attributes. Class diagram are more likely to map in to real-world objects, while ER diagrams most often map in to the tables in the database. Usually, relationships found in ER diagrams are more difficult to understand for humans than relationships in class diagrams.

Related Topic