Basic Concepts that every Data Modeler should know

Data modeling is an art as well as science. Data modeling is very important in the initial stage of the project. A good data model is assets for the project while the bad data model can become the liability for the project

Photo by William Iven on Unsplash

Peter Chen has started data modeling with his 1970 paper. He has discussed the basic concept of the Entity-relationship model. Thanks to Peter Chen we are living in a much better world now. In simple terms, the entity is a table containing the data and attributes are the fields in the table.

Entity
Attribute

a. Strong Entity:- A strong entity is an independent entity in the schema. Strong entities are represented by a rectangle box

b. Weak entity:- A weak entity is a dependent entity. Its existence depends on the strong entity. Weak entities are represented by a double rectangle box

Strong entity vs Weak Entity

i. Primary Key:- The key is chosen by the data modeler to uniquely identify the candidate in the entity.

ii. Foreign Key:- Use to identify the relationship with a primary key

Hierarchy

a. One to one: When every candidate of the first entity is connected to the only one candidate of the second entity.

b. One to many:- When every candidate of the first entity is connected to the one or more candidate of the second entity.

c. Mandatory relationship:- When every candidate of the first entity is connected to at least one candidate of the second entity. In general, a solid line represents the mandatory relationship

Mandatory relationship

d. Optional relationship:- When is the relationship between the first entity is not required with the second entity. A dashed line represents the optional relationship

Optional relationship

e. Many to Many:- When one or more candidate from the first entity can be connected to one or more candidate from the second entity

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store