Chapter 1
Chapter 1
DATABASE SYSTEMS
1
Book: Database Systems Design, Implementation, and Management
Coronel, C. and Morris, S. 2018. Database systems: design, implementation, & management. 13th Ed. Cengage Learning. USA.
DATA VS.
INFORMATION
Data Information
▪ Raw facts ▪ Produced by processing data
▪ Raw data - Not yet been ▪ Reveals the meaning of data
processed to reveal the ▪ Enables knowledge creation
meaning
▪ Should be accurate, relevant, and
▪ Building blocks of information timely to enable good decision
▪ Data management making
▪ Generation, storage, and
retrieval of data
DATABASE
▪ Shared, integrated computer structure that stores a collection of:
▪ End-user data - Raw facts of interest to end user
▪ Metadata: Data about data, which the end-user data are integrated and
managed
▪ Describe data characteristics and relationships
▪ Database management system (DBMS)
▪ Collection of programs
▪ Manages the database structure
▪ Controls access to data stored in the database
ROLE OF THE DBMS
▪ Intermediary between the user and the database
▪ Enables data to be shared
▪ Presents the end user with an integrated view of the data
▪ Receives and translates application requests into operations
required to fulfill the requests
▪ Hides database’s internal complexity from the application
programs and users
FIGURE 1.2 - THE DBMS MANAGES THE INTERACTION
BETWEEN THE END USER AND THE DATABASE
ADVANTAGES OF THE DBMS
• Better data integration and less data inconsistency
– Data inconsistency: Different versions of the same data
appear in different places
• Increased end-user productivity
• Improved:
▪ Data sharing
▪ Data security
▪ Data access
▪ Decision making
▪ Data quality: Promoting accuracy, validity, and
ADVANTAGES OF THE DBMS
▪ In particular, a DBMS provides these advantages:
▪ Improved data sharing. The DBMS helps create an environment in which end users have better
access to more and better-managed data. Such access makes it possible for end users to respond
quickly to changes in their environment.
▪ Improved data security. The more users access the data, the greater the risks of data security
breaches. Corporations invest considerable amounts of time, effort, and money to ensure that
corporate data is used properly. A DBMS provides a framework for better enforcement of data
privacy and security policies.
▪ Better data integration. Wider access to well-managed data promotes an integrated view of the
organization’s operations and a clearer view of the big picture. It becomes much easier to see how
actions in one segment of the company affect other segments.
▪ Minimized data inconsistency. Data inconsistency exists when different versions of the same data
appear in different places.
For example, data inconsistency exists when a company’s sales department stores a sales
representative’s name as Bill Brown and the company’s personnel department stores that same
person’s name as William G. Brown, or when the company’s regional sales office shows the price of a
product as $45.95 and its national sales office shows the same product’s price as $43.95. 7The
probability of data inconsistency is greatly reduced in a properly designed database.
▪ Improved data access. The DBMS makes it possible to produce quick answers to ad hoc queries.
From a database perspective, a query is a specific request issued to the DBMS for data
manipulation.
for example, to read or update the data. Simply put, a query is a question, and an ad hoc query is a
spur-of-the-moment question. The DBMS sends back an answer (called the query result set) to the
application. For example, when dealing with large amounts of sales data, end users might want
quick answers to questions (ad hoc queries). Some examples are the following:
–– What was the dollar volume of sales by product during the past six months?
–– What is the sales bonus figure for each of our salespeople during the past threemonths?
–– How many of our customers have credit balances of $3,000 or more?
8
TYPES OF DATABASES
• Single-user database: Supports one user at a time
▪ Desktop database: Runs on PC
▪ Multiuser database: Supports multiple users at the same time
▪ Workgroup databases: Supports a small number of users or a specific
department
▪ Enterprise database: Supports many users across many departments
▪ Centralized database: Data is located at a single site
▪ Distributed database: Data is distributed across different sites
▪ Cloud database: Created and maintained using cloud data services that
provide defined performance measures for the database
TYPES OF DATABASES
▪ General-purpose databases: Contains a wide variety of data used in
multiple disciplines
▪ Discipline-specific databases: Contains data focused on specific
subject areas
▪ Operational database: Designed to support a company’s day-
to-day operations
▪ Analytical database: Stores historical data and business metrics
used exclusively for tactical or strategic decision making
▪ Data warehouse: Stores data in a format optimized for decision support
TYPES OF DATABASES
▪ Online analytical processing (OLAP)
▪ Enable retrieving, processing, and modeling data from the data warehouse
▪ Business intelligence: Captures and processes business data to generate
information that support decision making
▪ Unstructured data: It exists in their original state
▪ Structured data: It results from formatting
▪ Structure is applied based on type of processing to be performed
▪ Semi structured data: Processed to some extent
▪ Extensible Markup Language (XML)
▪ Represents data elements in textual format
DATABASE DESIGN
▪ Focuses on the design of the database structure that will be used
to store and manage end-user data
▪ Well-designed database
▪ Facilitates data management
▪ Generates accurate and valuable information
▪ Poorly designed database causes difficult-to-trace errors
EVOLUTION OF FILE SYSTEM DATA PROCESSING
Manual File Systems
Extensive programming
STRUCTURAL AND DATA DEPENDENCE
▪ Structural dependence: Access to a file is dependent
on its own structure
▪ All file system programs are modified to conform to a
new file structure
▪ Structural independence: File structure is changed
without affecting the application’s ability to access
the data
STRUCTURAL AND DATA DEPENDENCE
▪ Data dependence
▪ Data access changes when data storage characteristics
change
▪ Data independence
▪ Data storage characteristics is changed without
affecting the program’s ability to access the data
▪ Practical significance of data dependence is
difference between logical and physical format
DATA REDUNDANCY
▪ Unnecessarily storing same data at different places
▪ Islands of information: Scattered data locations
▪ Increases the probability of having different versions of
the same data
DATA REDUNDANCY IMPLICATIONS
▪ Poor data security
▪ Data inconsistency
▪ Increased likelihood of data-entry errors when
complex entries are made in different files
▪ Data anomaly: Develops when not all of the required
changes in the redundant data are made successfully
TYPES OF DATA ANOMALY
Update Anomalies
Insertion Anomalies
Deletion Anomalies
LACK OF DESIGN AND DATA-MODELING SKILLS
▪ Evident despite the availability of multiple personal
productivity tools being available
▪ Data-modeling skills is vital in the data design
process
▪ Good data modeling facilitates communication
between the designer, user, and the developer
DATABASE SYSTEMS
▪ Logically related data stored in a single logical data
repository
▪ Physically distributed among multiple storage facilities
• DBMS eliminates most of file system’s problems
▪ Current generation DBMS software:
– Stores data structures, relationships between structures, and
access paths
– Defines, stores, and manages all access paths and
components
FIGURE 1.8 - CONTRASTING DATABASE AND FILE
THE DATABASE SYSTEM ENVIRONMENT
▪ The term database system refers to an organization of components that define and regulate the
collection, storage, management, and use of data within a database environment. From a general
management point of view, the database system is composed of the five major parts shown in Figure
1.9: hardware, software, people, procedures, and data.
▪ Let’s take a closer look at the five components shown in Figure 1.9:
▪ Hardware. Hardware refers to all of the system’s physical devices, including computers (PCs,
tablets, workstations, servers, and supercomputers), storage devices, printers, network devices
(hubs, switches, routers, fiber optics), and other devices (automated teller machines, ID readers, and
so on).
▪ Software. Although the most readily identified software is the DBMS itself, three types of software
are needed to make the database system function fully: operating system software, DBMS software,
and application programs and utilities.
–– Operating system software manages all hardware components and makes it possible for all other
software to run on the computers. Examples of operating system software are Microsoft Windows,
Linux, Mac OS, UNIX, and MVS.
–– DBMS software manages the database within the database system. Some examples of DBMS
software are Microsoft’s SQL Server, Oracle Corporation’s Oracle, Oracle’s MySQL, and IBM’s DB2.
25
▪ Application programs and utility software are used to access and manipulate data in the DBMS
and to manage the computer environment in which data access and manipulation take place.
Application programs are most commonly used to access data within the database to generate
reports, tabulations, and other information to facilitate decision making. Utilities are the software
tools used to help manage the database system’s computer components. For example, all of the
major DBMS vendors now provide graphical user interfaces (GUIs) to help create database
structures, control database access, and monitor database operations.
▪ People. This component includes all users of the database system. On the basis of primary job
functions, five types of users can be identified in a database system: system administrators,
database administrators, database designers, system analysts and programmers, and end users.
Each user type, described next, performs both unique and complementary functions.
–– System administrators oversee the database system’s general operations.
–– Database administrators, also known as DBAs, manage the DBMS and ensure that the database is
functioning properly. The DBA’s role is sufficiently important to warrant a detailed exploration in
Chapter 16, Database Administration and Security.
–– Database designers design the database structure. They are, in effect, the database architects. If
the database design is poor, even the best application programmers and the most dedicated DBAs
cannot produce a useful database environment. Because organizations strive to optimize their data
resources, the database designer’s job description has expanded to cover new dimensions and
growing responsibilities.
26
FIGURE 1.9 - THE DATABASE SYSTEM ENVIRONMENT
▪ –– System analysts and programmers design and implement the application programs. They
design and create the data-entry screens, reports, and procedures through which end users
access and manipulate the database’s data.
–– End users are the people who use the application programs to run the organization’s daily
operations. For example, sales clerks, supervisors, managers, and directors are all classified as end
users. High-level end users employ the information obtained from the database to make tactical
and strategic business decisions.
Procedures. Procedures are the instructions and rules that govern the design and use of the
database system. Procedures are a critical, although occasionally forgotten, component of the
system. Procedures play an important role in a company because they enforce the standards by
which business is conducted within the organization and with customers. Procedures also help to
ensure that companies have an organized way to monitor and audit the data that enter the database
and the information generated from those data.
Data. The word data covers the collection of facts stored in the database. Because data is the raw
material from which information is generated, determining which data to enter into the database
and how to organize that data is a vital part of th database designer’s job.
28
DBMS FUNCTIONS
Data dictionary management
• Data dictionary: Stores definitions of the data elements and their relationships
Security management
• Enforces user security and data privacy
DBMS FUNCTIONS
Multiuser access control
• Sophisticated algorithms ensure that multiple users can access the
database concurrently without compromising its integrity
• Query language: Lets the user specify what must be done without having to
specify how
• Structured Query Language (SQL): De facto query language and data access
standard supported by the majority of DBMS vendors
32