SlideShare a Scribd company logo
1 of 69
 Chapter 2
 Data Models
ISBN-13: 978-1337627900
ISBN-10: 1337627909
Buy Book Amazon.com URL
Modified by:
Usman Tariq, PhD
Associate Professor, PSAU
Office ☎ 00966 11 588 8386
Learning Objectives
 In this chapter, you will learn:
 About data modeling and why data models are
important
 About the basic data-modeling building blocks
 What business rules are and how they influence
database design
2
Learning Objectives
 In this chapter, you will learn:
 How the major data models evolved
 About emerging alternative data models and the need
they fulfill
 How data models can be classified by their level of
abstraction
3
Data Modeling and Data Models
• Data modeling: It is a process of creating a data model
for the data to be stored in a Database i.e. a conceptual
representation of
• Data objects
• The associations between different data objects
• The rules.
 Data modeling helps in the visual representation of data
and enforces business rules, regulatory compliances, and
government policies on the data. Data Models ensure
consistency in naming conventions, default values,
semantics, security while ensuring quality of the data.
4
Data Modeling and Data Models
Data model emphasizes on (1) what data is needed and
(2) how it should be organized instead of what
operations need to be performed on the data.
 Data models: Simple representations of complex
real-world data structures
 Useful for supporting a specific problem domain
 Model - Abstraction of a real-world object or event
5
Why use Data Model?
 The primary goal of using data model are:
1. Ensures that all data objects required by the database are accurately
represented. Omission of data will lead to creation of faulty reports and
produce incorrect results.
2. A data model helps design the database at the conceptual, physical and
logical levels.
3. Data Model structure helps to define the relational tables, primary and
foreign keys and stored procedures.
4. It provides a clear picture of the base data and can be used by database
developers to create a physical database.
5. It is also helpful to identify missing and redundant data.
6. Though the initial creation of data model is labor and time consuming, in
the long run, it makes your IT infrastructure upgrade and maintenance
cheaper and faster. 6
Types of Data Models [1/2]
 Conceptual: This Data Model defines WHAT the system
contains. This model is typically created by Business
stakeholders and Data Architects. The purpose is to organize,
scope and define business concepts and rules.
 Logical: Defines HOW the system should be implemented
regardless of the DBMS. This model is typically created by
Data Architects and Business Analysts. The purpose is to
developed technical map of rules and data structures.
 Physical: This Data Model describes HOW the system will be
implemented using a specific DBMS system. This model is
typically created by DBA and developers. The purpose is
actual implementation of the database.
7
Types of Data Models [2/2]
8
Advantages of Data model
 The main goal of a designing data model is to make certain that
data objects offered by the functional team are represented
accurately.
 The data model should be detailed enough to be used for building
the physical database.
 The information in the data model can be used for defining the
relationship between tables, primary and foreign keys, and stored
procedures.
 Data Model helps business to communicate the within and across
organizations.
 Data model helps to documents data mappings in ETL process
 Help to recognize correct sources of data to populate the model
9
Importance of Data Models
Are a communication tool
Give an overall view of the database
Organize data for various users
Are an abstraction for the creation of good
database
10
Disadvantages of Data model
 To develop Data model one should know
physical data stored characteristics.
 This is a navigational system produces
complex application development,
management. Thus, it requires a
knowledge of the biographical truth.
 Even smaller change made in structure
require modification in the entire
application.
 There is no set data manipulation
language in DBMS.
11Space in a Data File
Data Model Basic Building Blocks
 Entity: Unique and distinct object used to collect
and store data
 Attribute: Characteristic of an entity
 Relationship: Describes an association among
entities
 One-to-many (1:M)
 Many-to-many (M:N or M:M)
 One-to-one (1:1)
 Constraint: Set of rules to ensure data integrity
12
Business Rules
Brief, precise, and unambiguous description of a
policy, procedure, or principle
Enable defining the basic building blocks
Describe main and distinguishing characteristics
of the data
13
Implementing a constraint imposed by
a database oriented business rule
14
Business Process Mapping to Application Objects
15
Business Rule Transformation
16
Ask yourself the following questions,
before any modification
1. Will this rule be violated if I enter a new record into this
table?
2. Will this rule be violated if I do not enter a new record
into this table?
3. Will this rule be violated if I delete a record from this
table?
4. Will this rule be violated if I enter a value into this field?
5. Will this rule be violated if I do not enter a value into this
field?
6. Will this rule be violated if I update the value of this field?
7. Will this rule be violated if I delete the value of this field?
17
Business Rules are normalized to represent the
desired business level semantics
18
As-is Business Rule Model (Event-driven)
19
Sources of Business Rules
Company
managers
Policy makers
Department
managers
Written
documentation
Direct
interviews
with end users
20
Reasons for Identifying and Documenting
Business Rules
 Help standardize company’s view of data
 Communications tool between users and designers
 Allow designer to:
 Understand the nature, role, scope of data, and business
processes
 Develop appropriate relationship participation rules and
constraints
 Create an accurate data model
21
Translating Business Rules into ‘Data
Model Components’
 Nouns translate into entities
 Verbs translate into relationships among entities
 Relationships are bidirectional
 Questions to identify the relationship type
 How many instances of ‘B’ are related to one instance
of ‘A’?
 How many instances of ‘A’ are related to one instance
of ‘B’?
22
Naming Conventions
 Entity names - Required to:
 Be descriptive of the objects in the business
environment
 Use terminology that is familiar to the users
 Attribute name - Required to be descriptive of the
data represented by the attribute
 Proper naming:
 Facilitates communication between parties
 Promotes self-documentation
23
Database Naming Conventions Best Practices
1. Consistency is always the best policy.
2. Every table should have its own row identifier
3. Plural or singular names don’t really matter
4. Never allow the database to put in the constraint
names automatically
5. Avoid being redundant so you can avoid being
redundant
24
Hierarchical and Network Models
Hierarchical Models Network Models
 Manage large amounts of data
for complex manufacturing
projects
 Represented by an upside-
down tree which contains
segments
 Segments: Equivalent of a file
system’s record type
 Depicts a set of one-to-many
(1:M) relationships
 Represent complex data
relationships
 Improve database performance
and impose a database
standard
 Depicts both one-to-many
(1:M) and many-to-many
(M:N) relationships
25
Hierarchical Model
Advantages Disadvantages
 Promotes data sharing
 Parent/child relationship promotes
conceptual simplicity and data
integrity
 Database security is provided and
enforced by DBMS
 Efficient with 1:M relationships
 Requires knowledge of physical
data storage characteristics
 Navigational system requires
knowledge of hierarchical path
 Changes in structure require
changes in all application
programs
 Implementation limitations
 No data definition
 Lack of standards
26
Network Model
Advantages Disadvantages
 Conceptual simplicity
 Handles more relationship types
 Data access is flexible
 Data owner/member relationship
promotes data integrity
 Conformance to standards
 Includes data definition language
(DDL) and data manipulation
language (DML)
 System complexity limits
efficiency
 Navigational system yields
complex implementation,
application development, and
management
 Structural changes require
changes in all application
programs
27
Standard Database Concepts
28
 Schema
 Conceptual organization of the entire database as
viewed by the database administrator
 To add a new entity attribute in the relational model, you
need to modify the table definition. To add a new attribute
in the key-value store, you add a row to the key-value
store, which is why it is said to be “schema-less.”
 Schema is of three types: Physical schema, logical
schema and view schema.
 The design of a database at physical level is called physical schema. It describes how the data
stored on the disk or the physical storage.
 Design of database at logical level is called logical schema, programmers and database
administrator work at this level. At this level data can be described as certain types of data
records gets stored in data structures.
 Design of database at view level is called view schema. This generally describes end user
interaction with database systems.
Standard Database Concepts
 Subschema
 Portion of the database seen by the application programs that produce
the desired information from the data within the database
 A subschema provides a view of the database as seen by an
application program.
 This view is often a subset of the complete schema definition.
 A subschema is used at run time to provide the DBMS with a
description of those portions of the database that are accessible to the
application program.
 The subschema allows the user to view only that part of the
database that is of interest to him.
 The subschema defines the portion of the database as seen by the
application programs and the application programs can have different
view of data stored in the database. 29
Standard Database Concepts
30
 Data manipulation language (DML)
 Environment in which data can be managed and is used to work with the
data in the database
 SQL includes commands to insert, update, delete, and retrieve data within
the database tables.
 PL/SQL blocks can contain only standard SQL data manipulation language
(DML) commands such as SELECT, INSERT, UPDATE, and DELETE.
The use of data definition language (DDL) commands is not directly
supported in a PL/SQL block.
Standard Database Concepts
 Schema data definition language (DDL)
 Enables the database administrator to define the schema
components
 DDL allows a database administrator to define the
database structure, schema, and subschema.
 Sub-Schema DDL, allows application programs to
define the database components that will be used.
31
Standard Database Concepts
 Schema data definition language
 Data Definition allows the specification of not only a
set of relations but also information about each relation,
including:
 The schema for each relation.
 The domain of values associated with each attribute.
 Integrity constraints
 The set of indices to be maintained for each relations.
 Security and authorization information for each relation.
 The physical storage structure of each relation on disk.
32
Standard Database Concepts
 Schema data definition language (DDL) Commands
 CREATE
 ALTER
 The Oracle ALTER TABLE statement is used to add, modify, or drop/delete columns
in a table. The Oracle ALTER TABLE statement is also used to rename a table.
 DROP
 To remove a relation from an SQL database, we use the drop table command. The drop
table command deletes all information about the dropped relation from the database.
The command
drop table r 33
The Relational Model
 Produced an automatic transmission database that
replaced standard transmission databases
 Based on a relation
 Relation or table: Matrix composed of intersecting
tuple and attribute
 Tuple: Rows
 Attribute: Columns
 Describes a precise set of data manipulation
constructs
34
Relational Model
Advantages Disadvantages
 Structural independence is
promoted using independent
tables
 Tabular view improves
conceptual simplicity
 Ad hoc query capability is based
on SQL
 Isolates the end user from
physical-level details
 Improves implementation and
management simplicity
 Requires substantial hardware and
system software overhead
 Conceptual simplicity gives
untrained people the tools to use a
good system poorly
 May promote information
problems
35
Relational Database Management System(RDBMS)
 Performs basic functions provided by the hierarchical
and network DBMS systems
 Makes the relational data model easier to understand
and implement
 Hides the complexities of the relational model from
the user
36
Figure 2.2 - A Relational Diagram
Cengage Learning © 2018
37
SQL-Based Relational Database
Application
 End-user interface
 Allows end user to interact with the data
 Collection of tables stored in the database
 Each table is independent from another
 Rows in different tables are related based on common
values in common attributes
 SQL engine
 Executes all queries
38
The Entity Relationship Model
 Graphical representation of entities and their
relationships in a database structure
 Entity relationship diagram (ERD)
 Uses graphic representations to model database
components
 Entity instance or entity occurrence
 Rows in the relational table
 Connectivity: Term used to label the relationship
types
39
Entity Relationship Model
Advantages Disadvantages
 Visual modeling yields
conceptual simplicity
 Visual representation makes it
an effective communication
tool
 Is integrated with the dominant
relational model
 Limited constraint
representation
 Limited relationship
representation
 No data manipulation
language
 Loss of information content
occurs when attributes are
removed from entities to avoid
crowded displays
40
Figure 2.3 - The ER Model Notations
41
The Object-Oriented Data Model (OODM)
or Semantic Data Model
 Object-oriented database management system
(OODBMS)
 Based on OODM
 Object: Contains data and their relationships with
operations that are performed on it
 Basic building block for autonomous structures
 Abstraction of real-world entity
 Attributes - Describe the properties of an object
42
The Object-Oriented Data Model (OODM)
 Class: Collection of similar objects with shared
structure and behavior organized in a class hierarchy
 Class hierarchy: Resembles an upside-down tree in
which each class has only one parent
 Inheritance: Object inherits methods and attributes
of parent class
 Unified Modeling Language (UML)
 Describes sets of diagrams and symbols to graphically
model a system
43
Object-Oriented Model
Advantages Disadvantages
 Semantic content is added
 Visual representation includes
semantic content
 Inheritance promotes data
integrity
 Slow development of
standards caused vendors to
supply their own
enhancements
 Compromised widely accepted
standard
 Complex navigational system
 Learning curve is steep
 High system overhead slows
transactions
44
Figure 2.4 - A Comparison of OO, UML,
and ER Models
45
Object/Relational and XML
 Extended relational data model (ERDM)
 Supports OO features and complex data
representation
 Object/Relational Database Management System
(O/R DBMS)
 Based on ERDM, focuses on better data management
 Extensible Markup Language (XML)
 Manages unstructured data for efficient and
effective exchange of all data types
46
Big Data
 Aims to:
 Find new and better ways to manage large amounts of
web and sensor-generated data
 Provide high performance and scalability at a
reasonable cost
 Characteristics
 Volume
 Velocity
 Variety
47
Different formats of ‘big data’
 The three different formats of big data are:
 Structured: Organized data format with a fixed
schema. Ex: RDBMS
 Semi-Structured: Partially organized data which does
not have a fixed format. Ex: XML, JSON
 Unstructured: Unorganized data with an unknown
schema. Ex: Audio, video files etc.
48
Characteristics of Big Data
 Validity: correctness of data
 Variability: dynamic behavior
 Volatility: tendency to change in time
 Vulnerability: vulnerable to breach or attacks
 Visualization: visualizing meaningful usage of data
49
Big Data Challenges
Volume does not allow the usage of
conventional structures
Expensive
OLAP tools proved inconsistent dealing
with unstructured data
50
Big Data New Technologies
Hadoop
Hadoop Distributed
File System (HDFS)
MapReduce NoSQL
51
Big Data Tools
52
Big Data Applications
• Entertainment: Netflix and Amazon use Big Data to make shows and movie
recommendations to their users.
• Insurance: Uses Big data to predict illness, accidents and price their products
accordingly.
• Driver-less Cars: Google’s driver-less cars collect about one gigabyte of data per
second. These experiments require more and more data for their successful execution.
• Education: Opting for big data powered technology as a learning tool instead of
traditional lecture methods, which enhanced the learning of students as well aided the
teacher to track their performance better.
• Automobile: Rolls Royce has embraced Big Data by fitting hundreds of sensors into its
engines and propulsion systems, which record every tiny detail about their operation.
The changes in data in real-time are reported to engineers who will decide the best
course of action such as scheduling maintenance or dispatching engineering teams
should the problem require it.
• Government: A very interesting use of Big Data is in the field of politics to analyze
patterns and influence election results. Cambridge Analytica Ltd. is one such
organization which completely drives on data to change audience behavior and plays
a major role in the electoral process.
53
Big Data Use Cases https://www.oracle.com/big-data/guide/what-is-big-data.html
NoSQL Databases
 Not based on the relational model
 Support distributed database architectures
 Provide high scalability, high availability, and fault
tolerance
 Support large amounts of sparse data
 Geared toward performance rather than transaction
consistency
 Store data in key-value stores
54
55
NoSQL
Advantages Disadvantages
 High scalability, availability, and
fault tolerance are provided
 Uses low-cost commodity
hardware
 Supports Big Data
 4. Key-value model improves
storage efficiency
 In terms of data consistency, it
provides an eventually consistent
model
 Complex programming is
required
 There is no relationship support
 There is no transaction integrity
support
56
NoSQL and Relational Databases Comparison
57
NoSQL databases https://dev.to/lmolivera/everything-you-need-to-know-about-nosql-databases-3o3h
Figure 2.5 - A Simple Key-value Representation
58
Figure 2.6 - The Evolution of Data Models
59
Table 2.3 - Data Model Basic Terminology
Comparison
60
Figure 2.7 - Data Abstraction Levels
61
The External Model
 End users’ view of the data environment
 ER diagrams are used to represent the external views
 External schema: Specific representation of an
external view
62
Figure 2.8 - External Models for Tiny
College
63
The Conceptual Model
 Represents a global view of the entire database by the
entire organization
 Conceptual schema: Basis for the identification and
high-level description of the main data objects
 Has a macro-level view of data environment
 Is software and hardware independent
 Logical design: Task of creating a conceptual data
model
64
Figure 2.9 - Conceptual Model for Tiny College
65
The Internal Model
 Representing database as seen by the DBMS
mapping conceptual model to the DBMS
 Internal schema: Specific representation of an
internal model
 Uses the database constructs supported by the chosen
database
 Is software dependent and hardware independent
 Logical independence: Changing internal model
without affecting the conceptual model
66
Figure 2.10 - Internal Model for Tiny College
67
The Physical Model
 Operates at lowest level of abstraction
 Describes the way data are saved on storage media
such as disks or tapes
 Requires the definition of physical storage and data
access methods
 Relational model aimed at logical level
 Does not require physical-level details
 Physical independence: Changes in physical model
do not affect internal model
68
Table 2.4 - Levels of Data Abstraction
Cengage Learning © 2018
69

More Related Content

What's hot

Types of Database Models
Types of Database ModelsTypes of Database Models
Types of Database ModelsMurassa Gillani
 
Dbms relational model
Dbms relational modelDbms relational model
Dbms relational modelChirag vasava
 
Introduction to Database
Introduction to DatabaseIntroduction to Database
Introduction to DatabaseSiti Ismail
 
2 database system concepts and architecture
2 database system concepts and architecture2 database system concepts and architecture
2 database system concepts and architectureKumar
 
Relational Database Design
Relational Database DesignRelational Database Design
Relational Database DesignArchit Saxena
 
Object Relational Database Management System(ORDBMS)
Object Relational Database Management System(ORDBMS)Object Relational Database Management System(ORDBMS)
Object Relational Database Management System(ORDBMS)Rabin BK
 
Entity Relationship Model
Entity Relationship ModelEntity Relationship Model
Entity Relationship ModelSlideshare
 
Integrity Constraints
Integrity ConstraintsIntegrity Constraints
Integrity ConstraintsMegha yadav
 
Relational Database Management System
Relational Database Management SystemRelational Database Management System
Relational Database Management SystemMian Abdul Raheem
 
Lecture 01 introduction to database
Lecture 01 introduction to databaseLecture 01 introduction to database
Lecture 01 introduction to databaseemailharmeet
 
Er & eer to relational mapping
Er & eer to relational mappingEr & eer to relational mapping
Er & eer to relational mappingsaurabhshertukde
 
Basic Concept of Database
Basic Concept of DatabaseBasic Concept of Database
Basic Concept of DatabaseMarlon Jamera
 
2. Entity Relationship Model in DBMS
2. Entity Relationship Model in DBMS2. Entity Relationship Model in DBMS
2. Entity Relationship Model in DBMSkoolkampus
 
Introduction & history of dbms
Introduction & history of dbmsIntroduction & history of dbms
Introduction & history of dbmssethu pm
 

What's hot (20)

Types of Database Models
Types of Database ModelsTypes of Database Models
Types of Database Models
 
Dbms relational model
Dbms relational modelDbms relational model
Dbms relational model
 
Introduction to Database
Introduction to DatabaseIntroduction to Database
Introduction to Database
 
2 database system concepts and architecture
2 database system concepts and architecture2 database system concepts and architecture
2 database system concepts and architecture
 
Relational Database Design
Relational Database DesignRelational Database Design
Relational Database Design
 
Data Dictionary
Data DictionaryData Dictionary
Data Dictionary
 
Files Vs DataBase
Files Vs DataBaseFiles Vs DataBase
Files Vs DataBase
 
Data Models
Data ModelsData Models
Data Models
 
Object Relational Database Management System(ORDBMS)
Object Relational Database Management System(ORDBMS)Object Relational Database Management System(ORDBMS)
Object Relational Database Management System(ORDBMS)
 
Entity Relationship Model
Entity Relationship ModelEntity Relationship Model
Entity Relationship Model
 
Data Base Management System
Data Base Management SystemData Base Management System
Data Base Management System
 
Data models
Data modelsData models
Data models
 
Elmasri Navathe DBMS Unit-1 ppt
Elmasri Navathe DBMS Unit-1 pptElmasri Navathe DBMS Unit-1 ppt
Elmasri Navathe DBMS Unit-1 ppt
 
Integrity Constraints
Integrity ConstraintsIntegrity Constraints
Integrity Constraints
 
Relational Database Management System
Relational Database Management SystemRelational Database Management System
Relational Database Management System
 
Lecture 01 introduction to database
Lecture 01 introduction to databaseLecture 01 introduction to database
Lecture 01 introduction to database
 
Er & eer to relational mapping
Er & eer to relational mappingEr & eer to relational mapping
Er & eer to relational mapping
 
Basic Concept of Database
Basic Concept of DatabaseBasic Concept of Database
Basic Concept of Database
 
2. Entity Relationship Model in DBMS
2. Entity Relationship Model in DBMS2. Entity Relationship Model in DBMS
2. Entity Relationship Model in DBMS
 
Introduction & history of dbms
Introduction & history of dbmsIntroduction & history of dbms
Introduction & history of dbms
 

Similar to Data Models Chapter Explained

Data Models [DATABASE SYSTEMS: Design, Implementation, and Management]
Data Models [DATABASE SYSTEMS: Design, Implementation, and Management]Data Models [DATABASE SYSTEMS: Design, Implementation, and Management]
Data Models [DATABASE SYSTEMS: Design, Implementation, and Management]Usman Tariq
 
Data modeling 101 - Basics - Software Domain
Data modeling 101 - Basics - Software DomainData modeling 101 - Basics - Software Domain
Data modeling 101 - Basics - Software DomainAbdul Ahad
 
1.1 Data Modelling - Part I (Understand Data Model).pdf
1.1 Data Modelling - Part I (Understand Data Model).pdf1.1 Data Modelling - Part I (Understand Data Model).pdf
1.1 Data Modelling - Part I (Understand Data Model).pdfRakeshKumar145431
 
Physical Database Requirements.pdf
Physical Database Requirements.pdfPhysical Database Requirements.pdf
Physical Database Requirements.pdfseifusisay06
 
1-SDLC - Development Models – Waterfall, Rapid Application Development, Agile...
1-SDLC - Development Models – Waterfall, Rapid Application Development, Agile...1-SDLC - Development Models – Waterfall, Rapid Application Development, Agile...
1-SDLC - Development Models – Waterfall, Rapid Application Development, Agile...JOHNLEAK1
 
Week 2 Characteristics & Benefits of a Database & Types of Data Models
Week 2 Characteristics & Benefits of a Database & Types of Data ModelsWeek 2 Characteristics & Benefits of a Database & Types of Data Models
Week 2 Characteristics & Benefits of a Database & Types of Data Modelsoudesign
 
Bca examination 2016 dbms
Bca examination 2016 dbmsBca examination 2016 dbms
Bca examination 2016 dbmsAnjaan Gajendra
 
A relational model of data for large shared data banks
A relational model of data for large shared data banksA relational model of data for large shared data banks
A relational model of data for large shared data banksSammy Alvarez
 
Methodology conceptual databases design roll no. 99 & 111
Methodology conceptual databases design roll no. 99 & 111Methodology conceptual databases design roll no. 99 & 111
Methodology conceptual databases design roll no. 99 & 111Manoj Nolkha
 
Advanced Database Systems CS352Unit 2 Individual Project.docx
Advanced Database Systems CS352Unit 2 Individual Project.docxAdvanced Database Systems CS352Unit 2 Individual Project.docx
Advanced Database Systems CS352Unit 2 Individual Project.docxnettletondevon
 
Is 581 milestone 7 and 8 case study coastline systems consulting
Is 581 milestone 7 and 8 case study coastline systems consultingIs 581 milestone 7 and 8 case study coastline systems consulting
Is 581 milestone 7 and 8 case study coastline systems consultingprintwork4849
 
Database Management System
Database Management SystemDatabase Management System
Database Management SystemTamur Iqbal
 

Similar to Data Models Chapter Explained (20)

Data Models [DATABASE SYSTEMS: Design, Implementation, and Management]
Data Models [DATABASE SYSTEMS: Design, Implementation, and Management]Data Models [DATABASE SYSTEMS: Design, Implementation, and Management]
Data Models [DATABASE SYSTEMS: Design, Implementation, and Management]
 
Data modeling 101 - Basics - Software Domain
Data modeling 101 - Basics - Software DomainData modeling 101 - Basics - Software Domain
Data modeling 101 - Basics - Software Domain
 
1.1 Data Modelling - Part I (Understand Data Model).pdf
1.1 Data Modelling - Part I (Understand Data Model).pdf1.1 Data Modelling - Part I (Understand Data Model).pdf
1.1 Data Modelling - Part I (Understand Data Model).pdf
 
Physical Database Requirements.pdf
Physical Database Requirements.pdfPhysical Database Requirements.pdf
Physical Database Requirements.pdf
 
Data Modeling.docx
Data Modeling.docxData Modeling.docx
Data Modeling.docx
 
1-SDLC - Development Models – Waterfall, Rapid Application Development, Agile...
1-SDLC - Development Models – Waterfall, Rapid Application Development, Agile...1-SDLC - Development Models – Waterfall, Rapid Application Development, Agile...
1-SDLC - Development Models – Waterfall, Rapid Application Development, Agile...
 
Dbms notes
Dbms notesDbms notes
Dbms notes
 
Week 2 Characteristics & Benefits of a Database & Types of Data Models
Week 2 Characteristics & Benefits of a Database & Types of Data ModelsWeek 2 Characteristics & Benefits of a Database & Types of Data Models
Week 2 Characteristics & Benefits of a Database & Types of Data Models
 
Bca examination 2016 dbms
Bca examination 2016 dbmsBca examination 2016 dbms
Bca examination 2016 dbms
 
Mis chapter 7 database systems
Mis chapter 7 database systemsMis chapter 7 database systems
Mis chapter 7 database systems
 
A relational model of data for large shared data banks
A relational model of data for large shared data banksA relational model of data for large shared data banks
A relational model of data for large shared data banks
 
Dbms models
Dbms modelsDbms models
Dbms models
 
DBMS-Unit-1.pptx
DBMS-Unit-1.pptxDBMS-Unit-1.pptx
DBMS-Unit-1.pptx
 
Methodology conceptual databases design roll no. 99 & 111
Methodology conceptual databases design roll no. 99 & 111Methodology conceptual databases design roll no. 99 & 111
Methodology conceptual databases design roll no. 99 & 111
 
Dbms unit i
Dbms unit iDbms unit i
Dbms unit i
 
Advanced Database Systems CS352Unit 2 Individual Project.docx
Advanced Database Systems CS352Unit 2 Individual Project.docxAdvanced Database Systems CS352Unit 2 Individual Project.docx
Advanced Database Systems CS352Unit 2 Individual Project.docx
 
Is 581 milestone 7 and 8 case study coastline systems consulting
Is 581 milestone 7 and 8 case study coastline systems consultingIs 581 milestone 7 and 8 case study coastline systems consulting
Is 581 milestone 7 and 8 case study coastline systems consulting
 
Database Management System
Database Management SystemDatabase Management System
Database Management System
 
RDBMS to NoSQL. An overview.
RDBMS to NoSQL. An overview.RDBMS to NoSQL. An overview.
RDBMS to NoSQL. An overview.
 
Data models
Data modelsData models
Data models
 

More from Usman Tariq

Distributed database management systems
Distributed database management systemsDistributed database management systems
Distributed database management systemsUsman Tariq
 
Database performance tuning and query optimization
Database performance tuning and query optimizationDatabase performance tuning and query optimization
Database performance tuning and query optimizationUsman Tariq
 
Database Systems
Database SystemsDatabase Systems
Database SystemsUsman Tariq
 
Io t in 5g aeon iccais-riyadh
Io t in 5g aeon iccais-riyadhIo t in 5g aeon iccais-riyadh
Io t in 5g aeon iccais-riyadhUsman Tariq
 
Data science Prospects
Data science Prospects Data science Prospects
Data science Prospects Usman Tariq
 
Database Systems
Database SystemsDatabase Systems
Database SystemsUsman Tariq
 
e-Marketing Research
e-Marketing Researche-Marketing Research
e-Marketing ResearchUsman Tariq
 
ERP modules and business software package
ERP modules and business software packageERP modules and business software package
ERP modules and business software packageUsman Tariq
 
ERP Implementation Challenges and Package Selection
ERP Implementation Challenges and Package SelectionERP Implementation Challenges and Package Selection
ERP Implementation Challenges and Package SelectionUsman Tariq
 
Global E-Markets 3.0
Global E-Markets 3.0Global E-Markets 3.0
Global E-Markets 3.0Usman Tariq
 
ERP Planning and Implementation
ERP Planning and ImplementationERP Planning and Implementation
ERP Planning and ImplementationUsman Tariq
 
Customer Relationship Management (CRM)
Customer Relationship Management (CRM)Customer Relationship Management (CRM)
Customer Relationship Management (CRM)Usman Tariq
 
The e-Marketing Plan
The e-Marketing PlanThe e-Marketing Plan
The e-Marketing PlanUsman Tariq
 
Strategic E-Marketing and Performance Metrics
Strategic E-Marketing and Performance MetricsStrategic E-Marketing and Performance Metrics
Strategic E-Marketing and Performance MetricsUsman Tariq
 
What is an erp system?
What is an erp system?What is an erp system?
What is an erp system?Usman Tariq
 
E-Marketing (past, present, and future)
E-Marketing (past, present, and future)E-Marketing (past, present, and future)
E-Marketing (past, present, and future)Usman Tariq
 
ERP and related technology
ERP and related technology ERP and related technology
ERP and related technology Usman Tariq
 
An overview - Enterprise
An overview - EnterpriseAn overview - Enterprise
An overview - EnterpriseUsman Tariq
 

More from Usman Tariq (18)

Distributed database management systems
Distributed database management systemsDistributed database management systems
Distributed database management systems
 
Database performance tuning and query optimization
Database performance tuning and query optimizationDatabase performance tuning and query optimization
Database performance tuning and query optimization
 
Database Systems
Database SystemsDatabase Systems
Database Systems
 
Io t in 5g aeon iccais-riyadh
Io t in 5g aeon iccais-riyadhIo t in 5g aeon iccais-riyadh
Io t in 5g aeon iccais-riyadh
 
Data science Prospects
Data science Prospects Data science Prospects
Data science Prospects
 
Database Systems
Database SystemsDatabase Systems
Database Systems
 
e-Marketing Research
e-Marketing Researche-Marketing Research
e-Marketing Research
 
ERP modules and business software package
ERP modules and business software packageERP modules and business software package
ERP modules and business software package
 
ERP Implementation Challenges and Package Selection
ERP Implementation Challenges and Package SelectionERP Implementation Challenges and Package Selection
ERP Implementation Challenges and Package Selection
 
Global E-Markets 3.0
Global E-Markets 3.0Global E-Markets 3.0
Global E-Markets 3.0
 
ERP Planning and Implementation
ERP Planning and ImplementationERP Planning and Implementation
ERP Planning and Implementation
 
Customer Relationship Management (CRM)
Customer Relationship Management (CRM)Customer Relationship Management (CRM)
Customer Relationship Management (CRM)
 
The e-Marketing Plan
The e-Marketing PlanThe e-Marketing Plan
The e-Marketing Plan
 
Strategic E-Marketing and Performance Metrics
Strategic E-Marketing and Performance MetricsStrategic E-Marketing and Performance Metrics
Strategic E-Marketing and Performance Metrics
 
What is an erp system?
What is an erp system?What is an erp system?
What is an erp system?
 
E-Marketing (past, present, and future)
E-Marketing (past, present, and future)E-Marketing (past, present, and future)
E-Marketing (past, present, and future)
 
ERP and related technology
ERP and related technology ERP and related technology
ERP and related technology
 
An overview - Enterprise
An overview - EnterpriseAn overview - Enterprise
An overview - Enterprise
 

Recently uploaded

Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsRizwan Syed
 
Science&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdfScience&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdfjimielynbastida
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsMiki Katsuragi
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr LapshynFwdays
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraDeakin University
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDGMarianaLemus7
 

Recently uploaded (20)

Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL Certs
 
Science&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdfScience&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdf
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering Tips
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning era
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDG
 

Data Models Chapter Explained

  • 1.  Chapter 2  Data Models ISBN-13: 978-1337627900 ISBN-10: 1337627909 Buy Book Amazon.com URL Modified by: Usman Tariq, PhD Associate Professor, PSAU Office ☎ 00966 11 588 8386
  • 2. Learning Objectives  In this chapter, you will learn:  About data modeling and why data models are important  About the basic data-modeling building blocks  What business rules are and how they influence database design 2
  • 3. Learning Objectives  In this chapter, you will learn:  How the major data models evolved  About emerging alternative data models and the need they fulfill  How data models can be classified by their level of abstraction 3
  • 4. Data Modeling and Data Models • Data modeling: It is a process of creating a data model for the data to be stored in a Database i.e. a conceptual representation of • Data objects • The associations between different data objects • The rules.  Data modeling helps in the visual representation of data and enforces business rules, regulatory compliances, and government policies on the data. Data Models ensure consistency in naming conventions, default values, semantics, security while ensuring quality of the data. 4
  • 5. Data Modeling and Data Models Data model emphasizes on (1) what data is needed and (2) how it should be organized instead of what operations need to be performed on the data.  Data models: Simple representations of complex real-world data structures  Useful for supporting a specific problem domain  Model - Abstraction of a real-world object or event 5
  • 6. Why use Data Model?  The primary goal of using data model are: 1. Ensures that all data objects required by the database are accurately represented. Omission of data will lead to creation of faulty reports and produce incorrect results. 2. A data model helps design the database at the conceptual, physical and logical levels. 3. Data Model structure helps to define the relational tables, primary and foreign keys and stored procedures. 4. It provides a clear picture of the base data and can be used by database developers to create a physical database. 5. It is also helpful to identify missing and redundant data. 6. Though the initial creation of data model is labor and time consuming, in the long run, it makes your IT infrastructure upgrade and maintenance cheaper and faster. 6
  • 7. Types of Data Models [1/2]  Conceptual: This Data Model defines WHAT the system contains. This model is typically created by Business stakeholders and Data Architects. The purpose is to organize, scope and define business concepts and rules.  Logical: Defines HOW the system should be implemented regardless of the DBMS. This model is typically created by Data Architects and Business Analysts. The purpose is to developed technical map of rules and data structures.  Physical: This Data Model describes HOW the system will be implemented using a specific DBMS system. This model is typically created by DBA and developers. The purpose is actual implementation of the database. 7
  • 8. Types of Data Models [2/2] 8
  • 9. Advantages of Data model  The main goal of a designing data model is to make certain that data objects offered by the functional team are represented accurately.  The data model should be detailed enough to be used for building the physical database.  The information in the data model can be used for defining the relationship between tables, primary and foreign keys, and stored procedures.  Data Model helps business to communicate the within and across organizations.  Data model helps to documents data mappings in ETL process  Help to recognize correct sources of data to populate the model 9
  • 10. Importance of Data Models Are a communication tool Give an overall view of the database Organize data for various users Are an abstraction for the creation of good database 10
  • 11. Disadvantages of Data model  To develop Data model one should know physical data stored characteristics.  This is a navigational system produces complex application development, management. Thus, it requires a knowledge of the biographical truth.  Even smaller change made in structure require modification in the entire application.  There is no set data manipulation language in DBMS. 11Space in a Data File
  • 12. Data Model Basic Building Blocks  Entity: Unique and distinct object used to collect and store data  Attribute: Characteristic of an entity  Relationship: Describes an association among entities  One-to-many (1:M)  Many-to-many (M:N or M:M)  One-to-one (1:1)  Constraint: Set of rules to ensure data integrity 12
  • 13. Business Rules Brief, precise, and unambiguous description of a policy, procedure, or principle Enable defining the basic building blocks Describe main and distinguishing characteristics of the data 13
  • 14. Implementing a constraint imposed by a database oriented business rule 14
  • 15. Business Process Mapping to Application Objects 15
  • 17. Ask yourself the following questions, before any modification 1. Will this rule be violated if I enter a new record into this table? 2. Will this rule be violated if I do not enter a new record into this table? 3. Will this rule be violated if I delete a record from this table? 4. Will this rule be violated if I enter a value into this field? 5. Will this rule be violated if I do not enter a value into this field? 6. Will this rule be violated if I update the value of this field? 7. Will this rule be violated if I delete the value of this field? 17
  • 18. Business Rules are normalized to represent the desired business level semantics 18
  • 19. As-is Business Rule Model (Event-driven) 19
  • 20. Sources of Business Rules Company managers Policy makers Department managers Written documentation Direct interviews with end users 20
  • 21. Reasons for Identifying and Documenting Business Rules  Help standardize company’s view of data  Communications tool between users and designers  Allow designer to:  Understand the nature, role, scope of data, and business processes  Develop appropriate relationship participation rules and constraints  Create an accurate data model 21
  • 22. Translating Business Rules into ‘Data Model Components’  Nouns translate into entities  Verbs translate into relationships among entities  Relationships are bidirectional  Questions to identify the relationship type  How many instances of ‘B’ are related to one instance of ‘A’?  How many instances of ‘A’ are related to one instance of ‘B’? 22
  • 23. Naming Conventions  Entity names - Required to:  Be descriptive of the objects in the business environment  Use terminology that is familiar to the users  Attribute name - Required to be descriptive of the data represented by the attribute  Proper naming:  Facilitates communication between parties  Promotes self-documentation 23
  • 24. Database Naming Conventions Best Practices 1. Consistency is always the best policy. 2. Every table should have its own row identifier 3. Plural or singular names don’t really matter 4. Never allow the database to put in the constraint names automatically 5. Avoid being redundant so you can avoid being redundant 24
  • 25. Hierarchical and Network Models Hierarchical Models Network Models  Manage large amounts of data for complex manufacturing projects  Represented by an upside- down tree which contains segments  Segments: Equivalent of a file system’s record type  Depicts a set of one-to-many (1:M) relationships  Represent complex data relationships  Improve database performance and impose a database standard  Depicts both one-to-many (1:M) and many-to-many (M:N) relationships 25
  • 26. Hierarchical Model Advantages Disadvantages  Promotes data sharing  Parent/child relationship promotes conceptual simplicity and data integrity  Database security is provided and enforced by DBMS  Efficient with 1:M relationships  Requires knowledge of physical data storage characteristics  Navigational system requires knowledge of hierarchical path  Changes in structure require changes in all application programs  Implementation limitations  No data definition  Lack of standards 26
  • 27. Network Model Advantages Disadvantages  Conceptual simplicity  Handles more relationship types  Data access is flexible  Data owner/member relationship promotes data integrity  Conformance to standards  Includes data definition language (DDL) and data manipulation language (DML)  System complexity limits efficiency  Navigational system yields complex implementation, application development, and management  Structural changes require changes in all application programs 27
  • 28. Standard Database Concepts 28  Schema  Conceptual organization of the entire database as viewed by the database administrator  To add a new entity attribute in the relational model, you need to modify the table definition. To add a new attribute in the key-value store, you add a row to the key-value store, which is why it is said to be “schema-less.”  Schema is of three types: Physical schema, logical schema and view schema.  The design of a database at physical level is called physical schema. It describes how the data stored on the disk or the physical storage.  Design of database at logical level is called logical schema, programmers and database administrator work at this level. At this level data can be described as certain types of data records gets stored in data structures.  Design of database at view level is called view schema. This generally describes end user interaction with database systems.
  • 29. Standard Database Concepts  Subschema  Portion of the database seen by the application programs that produce the desired information from the data within the database  A subschema provides a view of the database as seen by an application program.  This view is often a subset of the complete schema definition.  A subschema is used at run time to provide the DBMS with a description of those portions of the database that are accessible to the application program.  The subschema allows the user to view only that part of the database that is of interest to him.  The subschema defines the portion of the database as seen by the application programs and the application programs can have different view of data stored in the database. 29
  • 30. Standard Database Concepts 30  Data manipulation language (DML)  Environment in which data can be managed and is used to work with the data in the database  SQL includes commands to insert, update, delete, and retrieve data within the database tables.  PL/SQL blocks can contain only standard SQL data manipulation language (DML) commands such as SELECT, INSERT, UPDATE, and DELETE. The use of data definition language (DDL) commands is not directly supported in a PL/SQL block.
  • 31. Standard Database Concepts  Schema data definition language (DDL)  Enables the database administrator to define the schema components  DDL allows a database administrator to define the database structure, schema, and subschema.  Sub-Schema DDL, allows application programs to define the database components that will be used. 31
  • 32. Standard Database Concepts  Schema data definition language  Data Definition allows the specification of not only a set of relations but also information about each relation, including:  The schema for each relation.  The domain of values associated with each attribute.  Integrity constraints  The set of indices to be maintained for each relations.  Security and authorization information for each relation.  The physical storage structure of each relation on disk. 32
  • 33. Standard Database Concepts  Schema data definition language (DDL) Commands  CREATE  ALTER  The Oracle ALTER TABLE statement is used to add, modify, or drop/delete columns in a table. The Oracle ALTER TABLE statement is also used to rename a table.  DROP  To remove a relation from an SQL database, we use the drop table command. The drop table command deletes all information about the dropped relation from the database. The command drop table r 33
  • 34. The Relational Model  Produced an automatic transmission database that replaced standard transmission databases  Based on a relation  Relation or table: Matrix composed of intersecting tuple and attribute  Tuple: Rows  Attribute: Columns  Describes a precise set of data manipulation constructs 34
  • 35. Relational Model Advantages Disadvantages  Structural independence is promoted using independent tables  Tabular view improves conceptual simplicity  Ad hoc query capability is based on SQL  Isolates the end user from physical-level details  Improves implementation and management simplicity  Requires substantial hardware and system software overhead  Conceptual simplicity gives untrained people the tools to use a good system poorly  May promote information problems 35
  • 36. Relational Database Management System(RDBMS)  Performs basic functions provided by the hierarchical and network DBMS systems  Makes the relational data model easier to understand and implement  Hides the complexities of the relational model from the user 36
  • 37. Figure 2.2 - A Relational Diagram Cengage Learning © 2018 37
  • 38. SQL-Based Relational Database Application  End-user interface  Allows end user to interact with the data  Collection of tables stored in the database  Each table is independent from another  Rows in different tables are related based on common values in common attributes  SQL engine  Executes all queries 38
  • 39. The Entity Relationship Model  Graphical representation of entities and their relationships in a database structure  Entity relationship diagram (ERD)  Uses graphic representations to model database components  Entity instance or entity occurrence  Rows in the relational table  Connectivity: Term used to label the relationship types 39
  • 40. Entity Relationship Model Advantages Disadvantages  Visual modeling yields conceptual simplicity  Visual representation makes it an effective communication tool  Is integrated with the dominant relational model  Limited constraint representation  Limited relationship representation  No data manipulation language  Loss of information content occurs when attributes are removed from entities to avoid crowded displays 40
  • 41. Figure 2.3 - The ER Model Notations 41
  • 42. The Object-Oriented Data Model (OODM) or Semantic Data Model  Object-oriented database management system (OODBMS)  Based on OODM  Object: Contains data and their relationships with operations that are performed on it  Basic building block for autonomous structures  Abstraction of real-world entity  Attributes - Describe the properties of an object 42
  • 43. The Object-Oriented Data Model (OODM)  Class: Collection of similar objects with shared structure and behavior organized in a class hierarchy  Class hierarchy: Resembles an upside-down tree in which each class has only one parent  Inheritance: Object inherits methods and attributes of parent class  Unified Modeling Language (UML)  Describes sets of diagrams and symbols to graphically model a system 43
  • 44. Object-Oriented Model Advantages Disadvantages  Semantic content is added  Visual representation includes semantic content  Inheritance promotes data integrity  Slow development of standards caused vendors to supply their own enhancements  Compromised widely accepted standard  Complex navigational system  Learning curve is steep  High system overhead slows transactions 44
  • 45. Figure 2.4 - A Comparison of OO, UML, and ER Models 45
  • 46. Object/Relational and XML  Extended relational data model (ERDM)  Supports OO features and complex data representation  Object/Relational Database Management System (O/R DBMS)  Based on ERDM, focuses on better data management  Extensible Markup Language (XML)  Manages unstructured data for efficient and effective exchange of all data types 46
  • 47. Big Data  Aims to:  Find new and better ways to manage large amounts of web and sensor-generated data  Provide high performance and scalability at a reasonable cost  Characteristics  Volume  Velocity  Variety 47
  • 48. Different formats of ‘big data’  The three different formats of big data are:  Structured: Organized data format with a fixed schema. Ex: RDBMS  Semi-Structured: Partially organized data which does not have a fixed format. Ex: XML, JSON  Unstructured: Unorganized data with an unknown schema. Ex: Audio, video files etc. 48
  • 49. Characteristics of Big Data  Validity: correctness of data  Variability: dynamic behavior  Volatility: tendency to change in time  Vulnerability: vulnerable to breach or attacks  Visualization: visualizing meaningful usage of data 49
  • 50. Big Data Challenges Volume does not allow the usage of conventional structures Expensive OLAP tools proved inconsistent dealing with unstructured data 50
  • 51. Big Data New Technologies Hadoop Hadoop Distributed File System (HDFS) MapReduce NoSQL 51
  • 53. Big Data Applications • Entertainment: Netflix and Amazon use Big Data to make shows and movie recommendations to their users. • Insurance: Uses Big data to predict illness, accidents and price their products accordingly. • Driver-less Cars: Google’s driver-less cars collect about one gigabyte of data per second. These experiments require more and more data for their successful execution. • Education: Opting for big data powered technology as a learning tool instead of traditional lecture methods, which enhanced the learning of students as well aided the teacher to track their performance better. • Automobile: Rolls Royce has embraced Big Data by fitting hundreds of sensors into its engines and propulsion systems, which record every tiny detail about their operation. The changes in data in real-time are reported to engineers who will decide the best course of action such as scheduling maintenance or dispatching engineering teams should the problem require it. • Government: A very interesting use of Big Data is in the field of politics to analyze patterns and influence election results. Cambridge Analytica Ltd. is one such organization which completely drives on data to change audience behavior and plays a major role in the electoral process. 53 Big Data Use Cases https://www.oracle.com/big-data/guide/what-is-big-data.html
  • 54. NoSQL Databases  Not based on the relational model  Support distributed database architectures  Provide high scalability, high availability, and fault tolerance  Support large amounts of sparse data  Geared toward performance rather than transaction consistency  Store data in key-value stores 54
  • 55. 55
  • 56. NoSQL Advantages Disadvantages  High scalability, availability, and fault tolerance are provided  Uses low-cost commodity hardware  Supports Big Data  4. Key-value model improves storage efficiency  In terms of data consistency, it provides an eventually consistent model  Complex programming is required  There is no relationship support  There is no transaction integrity support 56
  • 57. NoSQL and Relational Databases Comparison 57 NoSQL databases https://dev.to/lmolivera/everything-you-need-to-know-about-nosql-databases-3o3h
  • 58. Figure 2.5 - A Simple Key-value Representation 58
  • 59. Figure 2.6 - The Evolution of Data Models 59
  • 60. Table 2.3 - Data Model Basic Terminology Comparison 60
  • 61. Figure 2.7 - Data Abstraction Levels 61
  • 62. The External Model  End users’ view of the data environment  ER diagrams are used to represent the external views  External schema: Specific representation of an external view 62
  • 63. Figure 2.8 - External Models for Tiny College 63
  • 64. The Conceptual Model  Represents a global view of the entire database by the entire organization  Conceptual schema: Basis for the identification and high-level description of the main data objects  Has a macro-level view of data environment  Is software and hardware independent  Logical design: Task of creating a conceptual data model 64
  • 65. Figure 2.9 - Conceptual Model for Tiny College 65
  • 66. The Internal Model  Representing database as seen by the DBMS mapping conceptual model to the DBMS  Internal schema: Specific representation of an internal model  Uses the database constructs supported by the chosen database  Is software dependent and hardware independent  Logical independence: Changing internal model without affecting the conceptual model 66
  • 67. Figure 2.10 - Internal Model for Tiny College 67
  • 68. The Physical Model  Operates at lowest level of abstraction  Describes the way data are saved on storage media such as disks or tapes  Requires the definition of physical storage and data access methods  Relational model aimed at logical level  Does not require physical-level details  Physical independence: Changes in physical model do not affect internal model 68
  • 69. Table 2.4 - Levels of Data Abstraction Cengage Learning © 2018 69