Data Model
Data Model is the visual representation of data flow from the origin to desired state and it helps to
easily understand on the list of stages how data created and converted.
Data Model has many categories and it would be implemented based on business decisions. Models
can be created through reverse engineering, extracting structures from relational databases.
It will be help business to address better solutioning, continuous improvement, new strategies.
Type of Data Models: -
Conceptual Data Model
Logical Data Model
Physical Data Model
Conceptual Data Model: -
Conceptual Data Models provides high level comprehensive business data which is easy to
understand for both technical and non- technical people to align on project objective, scope and
design and this is the starting point for the future detailed data models.
This model helps to understand the Entities, Attributes, Data relationships and Data requirements
without depth analysis of technologies.
Product Planned
Customer Order Invoice Payment
Billing
Logical Data Model: -
Logical Data Model represents the Table, Columns and relationships between different data
structure and bridges the gap between conceptual and physical data models.
It translates the high-level concepts from the conceptual model into a more structured format that
can be implemented in a specific database system
Logical Data Model can be implemented for below databases
Columnar
Relational
Multidimensional
NoSQL systems
Physical Data Model: -
Physical Data model is more detailed representation than logical data model and it listed the details
about how the data will be stored and organized in a specific database system.
It takes the logical model and refines it based on the chosen database platform, accounting for
performance, storage, and other system-specific considerations.
Physical Data Model consist of
1. Data types
2. Table
3. Constraints
4. Index
5. Triggers
6. Partitioning
7. Auto Increment
Data Modeling Techniques
Hierarchical Data Model
Data is stored in a hierarchical tree-like structure. Here, the collection of data fields is
defined in terms of parent and child records. In such a structure, the child record has only
one parent, whereas the parent can have more than one child.
Example: - Information Management system
Network Data Model
An extension of hierarchical data models is network data models. It differs from hierarchical
models because one child record can have more than one parent.
ER Data Model: -
ER Model represents the abstracts of the entities and their relationship in the database.
Entities – It defines the tables which holds the data
o Independent Entity - Independent entities, also referred to as kernels, are the
backbone of the database
o Dependent Entity - Dependent entities, also referred to as derived entities, depend
on other tables for their meaning
o Characteristics Entity - Characteristic entities provide more information about
another table
Attributes – Each Entity is described with set of attributes
o Simple attributes
o Composite attributes
o Multivalued attributes
o Derived attributes
Keys - It is a constraint or condition of the attributes in the entities.
o Candidate key
o Composite key
o Primary key
o Secondary key
o Alternate key
o Foreign key
Relationships - It defines the connectivity between the two tables
o One to many (1:M) relationship
o One to one (1:1) relationship
o Many to many (M: N) relationships
o Unary relationship (recursive)
Ref: - https://opentextbc.ca/dbdesign01/chapter/chapter-8-entity-relationship-model/
Relational Data Model: -
The relational data model was introduced by E. F. Codd in 1970. Currently, it is the most
widely used data model.
Relational model represents data and its relationship by the way of collections of tables in
the database.
Table represents data by rows and columns
Object Oriented Data Model
The object-oriented data model aims at bridging the semantic gap between relation tables and
entities of the real world through objects that directly correspond to entities.
Object Oriented Data Model = Object Oriented Programming + Relational database model
Objects
o Objects is an abstraction of the real-world entity or instance of class.
Attributes
o It describes the properties of an object
Methods
o It describes the behaviour of an object
Class
o A class is a collection of similar objects with shared structure
Dimensional Data Model
Dimensional Data Model is one of the data models used in the data warehouse design it consists of
Fact Table, Dimension Tables.
The mail goal of this model is optimized way data retrieval and it commonly used in OLAP systems.
Fact Table
A fact table is a primary table in dimension modelling and it contains
Measurements/facts
Foreign key to dimension table
Dimension Table
A dimension table contains dimensions of a fact.
They are joined to fact table via a foreign key.
Dimension tables are de-normalized tables.
Dimensions offers descriptive characteristics of the facts with the help of their attributes
The dimension can also contain one or more hierarchical relationships
Types of Dimensions in Data Warehouse
Conformed Dimension
Outrigger Dimension
Shrunken Dimension
Role Playing Dimension
Dimension to Dimension
Junk Dimension
Degenerate Dimension
Swappable Dimension
Step Dimension