Database Design
Database Design
Database Design
• Database design is the organization of data according
to a database model.
• A database model is a type of data model that
determines the logical structure of a database and
fundamentally determines in which manner data can
be stored, organized and manipulated.
– Ex: relational model, which uses a table-based format.
Database Design
• The designer determines what data must be
stored and how the data elements interrelate.
• Database design involves classifying data and
identifying interrelationships.
Relational model
• It is a mathematical model defined in terms of
predicate logic and set theory, and
implementations of it have been used by
mainframe, midrange and microcomputer
systems.
• The products that are generally referred to as
relational databases.
– Ex: RDBMS
Entity Relationship Diagram
ERD
What is an ERD?
• An entity relationship diagram (ERD) shows the
relationships of entity sets stored in a database.
• An entity in this context is an object, a
component of data.
• An entity set is a collection of similar entities.
• These entities can have attributes that define its
properties.
What is an ERD?
• By defining the entities, their attributes, and
showing the relationships between them, an ER
diagram illustrates the logical structure of
databases.
One-to-many The primary key table contains only one record that relates to none, one, or many records in the related
table.
Many-to-many Each record in both tables can relate to none or any number of records in the other table. These
relationships require a third table, called an associate or linking table, because relational systems cannot
directly accommodate the relationship.