Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to decide whether to use ER or UML for modelling?

A UML diagram can be used both to model database designs and class designs, but an ER diagram should be used exclusively in database problems. How do you pick one graphical representation over the other?

like image 823
stallion Avatar asked Nov 07 '12 15:11

stallion


People also ask

Why are UML class diagrams are preferred over ER diagrams?

The results indicate that ER model is generally better in relationship name and participation representation than the UML class diagram. On the other hand, UML class diagrams provide a better representation for the cardinality relationship compared with ER diagrams.

What is the difference between UML and ER?

The main difference between UML and ER diagrams is that UML is a language used to create diagrams, whereas ERDs are a type of diagram. UML is used for planning software development, and is used in many different diagrams for various purposes.

What is ER model What is the advantage of using ER model?

ER model is used to represent real life scenarios as entities. The properties of these entities are their attributes in the ER diagram and their connections are shown in the form of relationships. An ER model is generally considered as a top down approach in data designing.

What are two reasons ER diagrams are used by software developers?

ER diagrams specify what data we will store: the entities and their attributes. They also show how entities relate to other entities. Another advantage of ERDs is that they represent the data in a graphical manner. This makes it easier for business folks to understand.


2 Answers

Just use always UML since it kind of subsumes ER. The only reason to use ER would be if you´re using a tool (e.g. to generate the DDL SQL scripts to create the tables) that only supports ER (now most do support UML but you may still find some that sticked to ER)

like image 29
Jordi Cabot Avatar answered Oct 04 '22 02:10

Jordi Cabot


ERD - Entity Relation Diagram - giving you image of how the tables should connect, what fields are going to be on each table, the tables connection, if many-to-many, one-to-many.

UML can be used for many diagrams other then ERD. sequence diagram, state diagram, more for the funcionality of the application (what user can do, who does it, when he does it, before what step, what table he use to do it) other then the tables description.

I Would use ERD to describe database relation and UML to describe operations, time, actions, etc..

Refer wiki : Entity-relationship_diagram & Unified_Modeling_Language

like image 200
ilansch Avatar answered Oct 04 '22 03:10

ilansch