Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 36

Chapter 1:

The Database Environment


and development process
(Part 1)
Modern Database Management
,Jeffrey A. Hoffer, Mary B. Prescott
Fred R. McFadden

1 by Prentice Hall 2007 ©


Objectives
 Definition of terms
 Explain growth and importance of databases
 Name limitations of conventional file processing
 Identify five categories of databases
 Explain advantages of databases
 Identify costs and risks of databases
 List components of database environment
 Describe evolution of database systems

Chapter 1 © 2007 by Prentice Hall 2


Definitions
 Database: organized collection of logically
related data
 Data: stored representations of meaningful
objects and events
 Structured: numbers, text, dates
 Unstructured: images, video, documents
 Information: data processed to increase
knowledge in the person using the data
 Metadata: data that describes the properties and
context of user data
Chapter 1 © 2007 by Prentice Hall 3
Figure 1-1a Data in context

Context helps users understand data

Chapter 1 © 2007 by Prentice Hall 4


Figure 1-1b Summarized data

Graphical displays turn data into useful


information that managers can use for
decision making and interpretation
Chapter 1 © 2007 by Prentice Hall 5
Descriptions of the properties or characteristics of the
data, including data types, field sizes, allowable
values, and data context

Chapter 1 © 2007 by Prentice Hall 6


File Possessing System

 A collection of application programs that perform services for the end-users


such as production of reports
 Each program defines and manages its own data
 Database systems arose in response to early methods of computerized
management of commercial data. As an example of such methods, typical
of the 1960s.

Chapter 1 © 2007 by Prentice Hall


Disadvantages of File Processing

 Program-Data Dependence
 File structure is defined in the program code.

 All programs maintain metadata for each file they use

 Duplication of Data
 Different systems/programs have separate copies of the same data

 Same data is held by different programs.

 Wasted space and potentially different values and/or different

formats for the same item.

Chapter 1 © 2007 by Prentice Hall 8


Disadvantages of File Processing cont..
 Limited Data Sharing
 No centralized control of data

 Programs are written in different languages, and so cannot easily access each other’s

files.
 Lengthy Development Times
 Programmers must design their own file formats

 Excessive Program Maintenance


 80% of information systems budget

 Vulnerable to Inconsistency
 Change in one table need changes in corresponding tables as well otherwise data will be

inconsistent

Chapter 1 © 2007 by Prentice Hall 9


Problems with Data Dependency
 Each application programmer must maintain
his/her own data
 Each application program needs to include
code for the metadata of each file
 Each application program must have its own
processing routines for reading, inserting,
updating, and deleting data
 Lack of coordination and central control
 Non-standard file formats

Chapter 1 © 2007 by Prentice Hall 10


Old file processing systems at Pine Valley Furniture
Company
Duplicate Data

Chapter 1 © 2007 by Prentice Hall 11


Problems with Data Redundancy

 Waste of space to have duplicate data


 Causes more maintenance headaches
 The biggest problem:
 Data changes in one file could cause

inconsistencies
 Compromises in data integrity (data reliability)

Chapter 1 © 2007 by Prentice Hall 12


SOLUTION:
The DATABASE Approach
 Central repository of shared data
 Data is managed by a controlling

agent
 Stored in a standardized, convenient

form

Requires a Database Management System (DBMS)

Chapter 1 © 2007 by Prentice Hall 13


Database Management System
 A software system that is used to create, maintain, and provide
controlled access to user databases
 (Database) application program: A computer program that
interacts with database by issuing an appropriate request (SQL
statement) to the DBMS

Order Filing
System

Invoicing Central database


DBMS
System
,Contains employee
,order, inventory
pricing, and
Payroll
customer data
System

DBMS manages data resources like an operating system manages hardware resources
Chapter 1 © 2007 by Prentice Hall 14
Advantages of the Database Approach
 Program-data independence
 Logical data independence
 Physical data independence
 Control data redundancy
 Improve data consistency
 Improve data sharing
 Increase application development productivity
 Enforcement of standards
 Improve data quality
 Providing backup and recovery
 Improve data accessibility and responsiveness
 Reduce program maintenance
 Improve decision support
Chapter 1 © 2007 by Prentice Hall 15
Advantages of the Database (cont..)
Allowing multiuser transaction processing:

A multiuser DBMS must allow multiple users to access the database at the same time and it has to ensure that concurrent
transactions operate correctly and efficiently. A transaction is an executing process that includes one or more database accesses
such reading or updating database records. The DBMS must enforce the following (ACID) properties.

 Atomicity: it ensures that either all operations in a transaction are executed or none are. For example, when you purchase
something from a point of sale (POS) terminal, a number of tasks are performed such as;
• Amount is deducted from your account.
• Amount is added in company's account.

All these tasks collectively are called an atomic unit of work or transaction. These tasks must be completed in all; otherwise
partially completed tasks are rolled back. Thus through DBMS, it is ensured that only consistent data exists within the
database.

 Isolation: it ensures that each transaction appears to execute in isolation of other transactions, even though hundreds of
transactions may be executing concurrently.

 Consistency: if each transaction has no logical error, execution of a transaction in isolation preserves the consistency of
the database.

 Durability: After a transaction completes successfully, the changes it has made to the database persist, even if there are
system failures.

Chapter 1 © 2007 by Prentice Hall


Costs and Risks of the Database
Approach
 New, specialized personnel
 Installation and management cost and
complexity
 Conversion costs
 Need for explicit backup and recovery
 Organizational conflict

Chapter 1 © 2007 by Prentice Hall 17


Elements of the Database Approach
 Data models
 Graphical system capturing nature and relationship of data
 Enterprise Data Model–high-level entities and relationships for
the organization
 Project Data Model–more detailed view, matching data structure
in database or data warehouse
 Relational Databases
 Database technology involving tables (relations) representing
entities and primary/foreign keys representing relationships
 Use of Internet Technology
 Networks and telecommunications, distributed databases, client-
server, and 3-tier architectures
 Database Applications
 Application programs used to perform database activities
(create, read, update, and delete) for database users

Chapter 1 © 2007 by Prentice Hall 18


Segment of an Enterprise Data Model

Segment of a Project-Level Data Model

Chapter 1 © 2007 by Prentice Hall 19


Components of the
Database Environment
 CASE Tools–computer-aided software engineering
 Repository–centralized storehouse of metadata
 Database Management System (DBMS) –software
for managing the database
 Database–storehouse of the data
 Application Programs–software using the data
 User Interface–text and graphical displays to users
 Data/Database Administrators–personnel
responsible for maintaining the database
 System Developers–personnel responsible for
designing databases and software
 End Users–people who use the applications and
databases
Chapter 1 © 2007 by Prentice Hall 20
Components of the Database Environment

Chapter 1 © 2007 by Prentice Hall 21


Database Languages

Data-Definition Language: Stands for "Data Definition Language."


A DDL is a language used to define data structures within a
database. It is typically considered to be a subset of SQL, the
Structured Query Language, but can also refer to languages that
define other types of data.
Example of DDL:- Create table Student(sid int, name varchar(50),
address varchar(50),level int, DOB Date, Primary Key(sid))

Chapter 1 © 2007 by Prentice Hall


Database Languages cont…

Data-Manipulation Language: A data-manipulation language (DML) is a language


that enables users to access or manipulate data as organized by the appropriate
data model. The types of access are:
1) Retrieval of information stored in the database
2) Insertion of new information into the database
3) Deletion of information from the database
4) Modification of information stored in the database
Example of DML:- Select cid,name,address from customer where cid = 1

The Data Control Language:- (DCL) is a subset of the Structured query language (SQL)
that allows database administrators to configure security access to relational databases.
Example of DCL:- GRANT SELECT ON HR.employees TO Joe

Chapter 1 © 2007 by Prentice Hall


The Range of Database Applications

 Personal databases
 Workgroup databases
 Departmental/divisional databases
 Enterprise database
 Enterprise resource planning (ERP) systems
 Data warehousing implementations

Chapter 1 © 2007 by Prentice Hall 24


Chapter 1 © 2007 by Prentice Hall 25
Typical data from a personal database

Chapter 1 © 2007 by Prentice Hall 26


Workgroup (Two-tier) database with wireless
local area network

Chapter 1 © 2007 by Prentice Hall 27


Three-tiered client/server database architecture

Chapter 1 28 © 2007 by Prentice Hall


Enterprise Database Applications

 Enterprise Resource Planning (ERP)


 Integrate all enterprise functions
(manufacturing, finance, sales, marketing,
inventory, accounting, human resources)
 Data Warehouse
 Integrated decision support system derived
from various operational databases

Chapter 1 © 2007 by Prentice Hall 29


Evolution of DB Systems

Chapter 1 © 2007 by Prentice Hall 30


History of DB Systems
 Flat files - 1960s - 1980s
 Hierarchical – 1970s - 1990s
 Network – 1970s - 1990s
 Relational – 1980s – present
 Oracle, DB2, SQL Server are all relational
 Easy to understand and use
 Good for most general purpose business
uses

Chapter 1 © 2007 by Prentice Hall 31


History of DB Systems
 Object-oriented – 1990s – present
 Store objects in databases
 These DBMS are specialized (not relational)
 Performance is good, but not easy to use
 Object-relational – 1990s – present
 Extend relational DBMS with
object-oriented features
(e.g., user defined data types)
 Full support for relational model

Chapter 1 © 2007 by Prentice Hall 32


History of DB Systems
 Data warehousing – 1980s – present
 Provide spreadsheet style analysis for database
E.g., breakdown sales by stores, products, quarters, years,
etc.
 Called warehouses because data stored in data
warehouses are only for analysis, not for daily operation
(so the data is not updated in real time)

Chapter 1 © 2007 by Prentice Hall 33


History of DB Systems
 Web-enabled – 1990s – present

User Query/Update
HTTP Input Database

HTML results
User with
Web browser results
(Internet Explorer) Web server Application server Database
(manages web site) E.g.: PHP, ASP Server
Chapter 1 E.g., Apache
© 2007 by Prentice Hall 34
History of DB Systems
 Web-enabled – 1990s – present

Product Ask for price


Catalog name

HTML prices
User with
Web browser prices
(Internet Explorer) Web server Application server Database
(manages web site) E.g.: PHP, ASP Server
Chapter 1 E.g., Apache
© 2007 by Prentice Hall 35
Current Status
 Relational database still has the most share of market
 Relational model is best for most common business needs

 All major DBMS can be accessed from web through server side
applications (ASP, PHP, Perl)
 Object-relational and data warehouses are value-adding features
 Can be found in major DBMS

 Useful for some users, not all

 Object-oriented DBMS have small but specialized market segments (e.g.,


Computer aided design)
 They are less popular because they do not support relational model

Chapter 1 © 2007 by Prentice Hall 36

You might also like