0% found this document useful (0 votes)
73 views

Datamodel

The document discusses different types of data models including hierarchical, network, relational, entity relationship, object-oriented, and how they relate to the internet. It provides details on each model including their characteristics, advantages, and disadvantages.
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
73 views

Datamodel

The document discusses different types of data models including hierarchical, network, relational, entity relationship, object-oriented, and how they relate to the internet. It provides details on each model including their characteristics, advantages, and disadvantages.
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 46

MC 9213 Database Management Systems

Dr. V. Jayanthi, PhD. Faculty, Dept. of Computer Applications

Introduction
Unit - 1

Data Models
Aug. 25 2010

Outline
Definitions

About Data Model


Types of data model Hierarchical Database Model

Network Database Model


Relational Database Model Entity Relationship Database Model Object-Oriented Database Model Development of Data Model Database Models and the Internet

Data Model
Definition: collection of logical constructs used to

represent data structure and relationships within the


database Data Model Operations: Operations for specifying database retrievals and updates by referring to the concepts of the data

model.
Operations on the data model may include basic operations and user-defined operations

Types of Data model


Conceptual models:
logical nature of data representation;
if emphasize on what entity is presented; it is used for database design as blueprint.

Implementation models:
emphasis on how the data are represented in the database

Database Models
Conceptual models include

Entity-relationship database model (ERDBD)


Object-oriented model (OODBM) Implementation models include Hierarchical database model (HDBM) Network database model (NDBM) Relational database model (RDBM) Object-oriented database model (ODBM)

Database Models (cont.)


Relationships in Conceptual Models
One-to-one (1:1) One-to-many (1:M)

Many-to-many (M:N)
Implementation Database Models Hierarchical - IMS (Information Management System)

Network CODASYL, IDMS (Integrated Data


Management System)

Relational - Oracle, DB2 (DataBase 2)

Object-Oriented GemStone, ObjectStore

Hierarchical Database Model (HDBM) (1)


Logically represented by an upside down tree
Each parent can have many children (segment linkage) Each child has only one parent

Hierarchical Database Model (2)


Logically represented by an upside down tree 1:M relationship

Hierarchical Database Model (4)


Hierarchical path (beginning from left) Left-list hierarchical path, or preorder traversal, or hierarchical sequence Final assembly->Component A->Assembly A-> -> Part A ->Part B -> Component B -> Component C Assembly B -> Part C >Part D

Re-list sequence, if the segment is frequently accessed

Bank systems commonly use HD model

Hierarchical data model (3)


Record based data model Hierarchical data model Organizes the data in a Tree Structure There is hierarchy of parents and child segments Data is represented by a collection of records types This restricts child segment having more than one parent E.g.: Information Management System (IMS) from IBM

Hierarchical Database Model (5)


Bank systems commonly use the HDBM

customer account can be subject to many


transactions (1:M relationship) Relationship is fixed (debiting and crediting) Frequently access large amount of transactions

Hierarchical Database Model (6)


Advantages
Conceptual simplicity: relationship between layers is logically simple; design process is simple
Database security: enforced uniformly through the system Data integrity Data independence

Efficiency in 1:M relationships and when uses require large numbers of transactions
Dominant in 1970s , when we used mainframe system with large databases

Hierarchical Database Model (6)


Disadvantages
Complex implementation: physical data storage characteristics; database design is complicated Difficult to manage and lack of standards Lacks structural independence

Applications programming and use complexity (pointer based)


Implementation limitations, i.e. especially it only handle 1:M type of model

Network Database Model (NDBM) (1)


Each record can have multiple parents

Called by Database Task Group (DBTG) to define standards


Three crucial database components
Network schema: conceptual organization of the entire database

Subschema: portion of database as information for application programs


Database management language: defining data characteristics and data structure Schema Data definition language (DDL): define schema components Subschema Data definition language

Data manipulating language: manipulate data content

Network Database Model (2)


Each record can have multiple parents Introduce set to describe relationship Each set has owner record and member record, parallel to parent and child in HDM Member may have several owners

One-ownership

Network Database Model (3)


Member may have several owners

Network data model (4)

Data in the network model is represented by a collection of records Relationships among data are represented by links (Pointers) The records in the database are collection of graphs E.g.: Integrated Data Management System (IDMS) from Honeywell

Network Database Model (5)


Advantages Conceptual simplicity, just lime HDM Handles more relationship types (but all 1:M relationship) Data access flexibility Promotes database integrity Data independence Conformance to standards

Network Database Model (6)


Disadvantages
System complexity Lack of structural independence

Relational Database Model (RDBM) (1)


Lets user or database designer to operate human logical environment

Tables are a series of row/column intersections


Tables related by sharing common entity characteristics

It allows 1:1, 1:M, M:N relationships


Perceived by user as a collection of tables for data storage, while let RDBMS handles the physical details.

Relational model basics (2)


Data is viewed as existing in two dimensional tables known as relations A relation (table) consists of unique attributes (columns) and tuples (rows) Tuples are unique

Sometimes the value to be inserted into a particular cell may be unknown, or it may have no value. This is represented by a null
Null is not the same as zero, blank or an empty string

Relational Database: Any database whose logical organization is based on relational data model.
RDBMS: A DBMS that manages the relational database.

Relational model basics (3)


Though logically data is viewed as existing in the form of

two dimensional tables, actually, the data is stored under


the file system only. The RDBMS provides an abstraction on top of the file system and gives an illusion that data resides in the form of tables.

Relational Database Model (4)

Relational data model (5)

Relational Database Model (6)


Advantages Structural independence: data access path is irrelevant to database design; change structure will not affect the database Improved conceptual simplicity Easier database design, implementation, management, and use Ad hoc query capability with SQL (4GL is added) Powerful database management system

Relational Database Model (7)


Disadvantages Substantial hardware and system software overhead

Poor design and implementation is made easy


May promote islands of information problems

Entity Relationship Database Model (ERDBM) (1)


Complements the relational data model concepts ERDBM introduces a relational graphic representation ERDBM is based on several components

Entity, tabled entity (in RDM)


Entity and entity set, a collection of like entities Each entity has attributes to describe the entity, which is similar to field in table Relationship and connection

Entity Relationship Database Model (ERDBM) (2)


Represented in an entity relationship diagram (ERD): Chens ERD model and Crows Foot ERD Based on entities, attributes, and relationships

Entity Relationship Database Model (3)


connection
entity

relationship

Entity Relationship Database Model (4)


Advantages

Exceptional conceptual simplicity


Visual representation Effective communication tool Integrated with the relational database model

Entity Relationship Database Model (5)


Disadvantages Limited constraint representation Limited relationship representation (internal relationship can not be depicted; multiple relationships) No data manipulation language (no complete) Loss of information content

Object-Oriented Database Model (OODBM) (1)


Semantic Data model (SDM)->Object-oriented Data Model (OODM)

Object-oriented concept:
Objects or abstractions of real-world entities are stored Attributes describe properties

Collection of similar objects is a class, similar to entity set but contains procedure methods
Methods represent real world actions of classes Classes are organized in a class hierarchy Inheritance is the ability of object to inherit attributes and methods of classes above it

Object-Oriented Database Model (OODBM) (2)


Contains implementation and procedure operation information for more complicated data such as graphics,

video, and other metadata


Support transaction and information Reusability Portable to powered computing system

Object-Oriented Database Model (3)

OO Database Model (4)


Advantages Adds semantic content

Visual presentation includes semantic content


Database integrity Both structural and data independence

OO Database Model (5)


Disadvantages

Lack of OODM
Complex navigational data access

Steep learning curve


High system overhead slows transactions

Database Models and the Internet (1)


Characteristics of Internet age databases
Flexible, efficient, and secure Internet access Easily used, developed, and supported

Supports complex data types and relationships


Seamless interfaces with multiple data sources and structures

Database Models and the Internet (2)


Simplicity of conceptual database model Many database design, implementation, and application development tools Powerful DBMS GUI make DBA job easier

Data Models: 1st Generation


Hierarchical Data Model implemented primarily by IBMs Information Management System (IMS) allows one-to-one or one-to-many relationships between entities

an entity at a many end of a relationship can be related to only one entity at the one end this model is navigational data access is through defined relationships, efficient if searches follow predefined relationships but performs poorly otherwise, e.g for ad-hoc queries.

Data Models: 1st Generation


Network Data Model
standard developed by the Committee on Data Systems Languages (CODASYL) allows one-to-one or one-to-many relationships between entities

allows multiple parentage a single entity can be at the many ends of multiple relationships
navigational

Data Models: 2nd Generation


Relational Data Model
developed by Edgar Codd (1970) data represented by simple tabular structures (relations)

relationships defined by primary keys and foreign keys


data accessed using high-level non-procedural language (SQL) separates logical and physical representation of data highly commercially successful (Oracle, DB2, SQL Server, etc) SQL is not computationally complete does not have the full power of a programming language Applications generally require the use of SQL statements embedded in another programming language.

Data Models: 3rd Generation


most programming languages are now object-oriented
Object Data Model offers persistence to objects, including their associations, attributes and operations requirements specified by Atkinson in 1989, standards proposed by Object Data Management Group (ODMG) navigational a step backwards from the relational model in some ways Object-Relational Model hybrid (or post-relational) model objects can be stored within relational database tables

proposed by Stonebraker (1990)


no accepted standards, but ORDBMS features supported by major commercial RDBMSs such as Oracle

You might also like