LECTURE 1 Introduction To Database
LECTURE 1 Introduction To Database
Fundamentals of Design,
Implementation, and
Management
Tenth Edition
Introduction to Database
Objectives
In this chapter, you will learn:
• The difference between data and information.
• What a database is, the various types of
databases, and why they are valuable assets for
decision making.
• How modern databases evolved from file systems.
• The importance of database design.
• About flaws in file system data management.
• The main components of the database system.
• The main functions of a database management
system (DBMS).
2
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Introduction
3
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Why Databases?
4
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Data vs. Information
5
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Data vs. Information (cont’d.)
8
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
9
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Role and Advantages of the DBMS
(cont’d.)
• Advantages of a DBMS:
– Improved data sharing- eg: Faculty, Academic, Finance share
students data
– Improved data security – eg: password policies
– Better data integration – eg: Academic department data + Faculties
data
– Minimized data inconsistency – eg: less data appear in different
places
– Improved data access – eg: quick answers to ad hoc queries
– Improved decision making
– Increased end-user productivity
10
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Types of Databases
• Databases can be classified according to:
– Number of users
– Database location(s)
– Expected type and extent of use
1. Number of users:
• Single-user database supports only one user at a time
– Desktop database: single-user; runs on PC
• Multiuser database supports multiple users at the same time
– Workgroup database (supports less than 50 users at the same time)
– Enterprise database (supports more than 50 users at the same time)
11
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Types of Databases (cont’d.)
2. Database location(s):
• Centralized database: data located at a single site
14
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
15
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
16
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Problems with File System Data
Processing
• Summary of file system limitations:
– Requires extensive programming
• Making changes to an existing file structure can be difficult
• Any change to a file structure, forces modifications in all of
the programs that use the data in that file
– Cannot perform ad hoc queries/quick answers
• Need to write programs to produce even the simplest
reports
– System administration is complex and difficult
• Each file must have its own file management programs that
allow the user to add, modify, and delete records, to list the
file contents and to generate report
17
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Problems with File System Data
Processing
• Summary of file system limitations:
– Difficult to make changes to existing structures
• Structural dependence : access to a file is dependent on its
structure. Eg : adding a field to a file – all of the file
programs must be modified to conform to the new file
structure
• Data dependence : all data access programs are subject to
change when any of the file’s data storage characteristics
change. Eg: changing a field from integer to decimal
– Security features are likely to be inadequate
• Security features are difficult to program and are often
omitted from a file system environment
• Insufficient for robust data sharing among users 18
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Data Redundancy
• File system structure makes it difficult to
combine data from multiple sources
– Vulnerable to security breaches
• Organizational structure promotes storage of
same data in different locations
– Islands of information (contain different versions of the same
data
• Data stored in different locations is unlikely to
be updated consistently
• Data redundancy: same data stored
unnecessarily in different places 19
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Data Redundancy (cont'd.)
20
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Data Redundancy (cont'd.)
– Update anomalies
• An Update Anomaly exists when one or more instances of duplicated data is updated,
but not all.
• For example, consider Jones moving address - you need to update all instances of
Jones's address.
21
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Data Redundancy (cont'd.)
22
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Data Redundancy (cont'd.)
– Deletion anomalies
• A Delete Anomaly exists when certain attributes are lost because of the deletion of
other attributes.
• For example, consider what happens if Student S30 is the last student to leave the
course - All information about the course is lost.
23
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Why Database Design Is Important
24
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Lack of Design and Data-Modeling
Skills
• Most users lack the skill to properly design
databases
– Despite multiple personal productivity tools
being available
• Data-modeling skills
– Vital in the data design process
• Good data modeling facilitates communication
between the designer, user, and the developer
25
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Database Systems
30
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
The Database System Environment
(cont'd.)
• People: all users of the database system
– System Administrator
• oversee the database system’s general operation
– database administrators
• manage the DBMS and ensure that the database is
functioning properly
– Database designers
• design the database structure
– Systems analysts and programmers
• design and implement the application programs
– End users
• people who use the application program 31
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
The Database System Environment
(cont'd.)
• Procedures: instructions and rules that govern
the design and use of the database system
• Data: the collection of facts stored in the
database
32
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
The Database System Environment
(cont'd.)
• Database systems are created and managed at
different levels of complexity
• Database solutions must be cost-effective as
well as tactically and strategically effective
• Database technology already in use affects
selection of a database system
33
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
DBMS Functions
39
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
DBMS Functions (cont'd.)
40
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
DBMS Functions (cont'd.)
41
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
DBMS Functions (cont'd.)
43
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Managing the Database System:
A Shift in Focus (cont'd.)
• Disadvantages of database systems:
– Increased costs – hardware, software, highly skilled
personnel, training etc.
– Management complexity – many different technologies.
– Maintaining currency – must keep your system current.
– Vendor dependence – heavy investment in technology
and personnel training, companies might be reluctant to
change database vendors.
– Frequent upgrade/replacement cycles – DBMS vendors
frequently upgrade their products by adding new functionality.
Some of the versions require hardware upgrades. Cost money
to train database users and administrators to properly use and
manage the new features.
44
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Preparing for Your Database
Professional Career
45
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Summary
DBMS Functions
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
ANSI-SPARC Three-Level
Architecture
(The American National Standards
Institute (ANSI)
Standards Planning and
Requirements Committee (SPARC))
48
Pearson
© 2013 Cengage Learning. All Rights Reserved. This edition Education
is intended © 2009
for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
ANSI-SPARC Three-Level
Architecture
• External Level
– Users’ view of the database.
– Describes that part of database that is
relevant to a particular user.
• Conceptual Level
– Community view of the database.
– Describes what data is stored in database and
relationships among the data.
49
Pearson
© 2013 Cengage Learning. All Rights Reserved. This edition Education
is intended © 2009
for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
ANSI-SPARC Three-Level
Architecture
• Internal Level
– Physical representation of the database on
the computer.
– Describes how the data is stored in the
database.
50
Pearson
© 2013 Cengage Learning. All Rights Reserved. This edition Education
is intended © 2009
for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Differences between Three Levels
of ANSI-SPARC Architecture
51
Pearson
© 2013 Cengage Learning. All Rights Reserved. This edition Education
is intended © 2009
for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Objectives of Three-Level
Architecture
52
Pearson
© 2013 Cengage Learning. All Rights Reserved. This edition Education
is intended © 2009
for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Objectives of Three-Level
Architecture
• Database Administrator (DBA) should be able
to change database storage structures without
affecting the users’ views.
• Internal structure of database should be
unaffected by changes to physical aspects of
storage.
• DBA should be able to change conceptual
structure of database without affecting all
users.
53
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
Pearsonaccessible
May not be scanned, copied, duplicated, or posted to a publicly Education © 2009
website, in whole or in part.
Summary
54
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.
Summary (cont'd.)
56
© 2013 Cengage Learning. All Rights Reserved. This edition is intended for use outside of the U.S. only, with content that may be different from the U.S. Edition.
May not be scanned, copied, duplicated, or posted to a publicly accessible website, in whole or in part.