Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

Data Isolation

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 16

INTRODUCTION TO MODERN DATABASE SYSTEMS o The same information being kept in

several different places (files).


Unit 1: Introduction to Modern Database Systems o Data inconsistency – a situation where
various copies of the same data are
1.1 Characteristics of Databases conflicting, wastes storage space and
Data duplicates effort.
 A collection of symbols used to represent 2. Data isolation
numbers, text, pictures, videos, audio, and so  Property that determines when and how
on. changes made by one operation become
Semantics visible to other concurrent users and
 Meaning for the symbols on how data is systems.
represented.  This issue occurs in a concurrency situation.
 Provided by the relationships that data has with  This is a problem because:
other data. o It is difficult for new applications to
 In programming, provided by program retrieve the appropriate data, which
documentation, as well as the programming might be stored in various files.
language used to create the program. 3. Integrity problems
 In databases, provided by a data model, which  Data Integrity – maintenance and
includes the representation of the data, assurance that the data in a database are
relationships among the data, and metadata correct and consistent.
(which is data that defines other data).  Factors to consider when addressing this
 Makes data useful. issue are:
Information o Data values must satisfy certain
 Useful data consistency constraints that are
 All information is data, but not all data is specified in the application programs.
information. o It is difficult to make changes to the
 The type and amount of semantics determines application programs in order to
the usefulness of some given data. enforce new constraints.
 Usefulness is also relative to a given user. Data 4. Security problems
may not be useful to some users, but very  Security can be a problem with a file-based
useful to others. approach because:
o There are constraints regarding
Adirenne Watt and Nelson Eng's Database Design: accessing privileges.
"Chapter 1: Before the Advent of Database o Application requirements are added to
Systems" the system in an ad-hoc manner so it is
difficult to enforce constraints.
File-based System 5. Concurrency access
 One way to keep information on a computer is  Concurrency – ability of the database to
to store it in permanent files. A company allow multiple users access to the same
system has a number of application programs; record without adversely affecting
each of them is designed to manipulate data transaction processing.
files. These application programs have been  A file-based system must manage, or
written at the request of the users in the prevent, concurrency by the application
organization. New applications are added to the programs. Typically, in a file-based system,
system as the need arises. when an application opens a file, that file is
locked. This means that no one else has
Disadvantages of the file-based approach access to the file at the same time.
1. Data redundancy  In database systems, concurrency is
 A situation that occurs in a database when a managed thus allowing multiple users
field needs to be updated in more than one access to the same record. This is an
table. important difference between database and
 Can lead to several problems such as: file-based systems.
o Inconsistency in data format
Database Approach database approach: allows the management of
 The difficulties that arise from using the file- large amounts of organizational information
based system have prompted the development
of a new approach in managing large amounts database management software: a powerful
of organizational information called the software tool that allows you to store, manipulate
database approach. and retrieve data in a variety of ways

Database management software file-based system: an application program designed


 Powerful software tool that allows you to store, to manipulate data files
manipulate and retrieve data in a variety of
different ways. Adirenne Watt and Nelson Eng's Database Design:
"Chapter 2: Fundamental Concepts" and "Chapter
Data 3: Characteristics and Benefits of a Database"
 Factual information such as measurements or
statistics about objects and concepts. Database
 A single fact is an element of data, or a data  A shared collection of related data used to
element. support the activities of a particular
 Data can be stored in: organization.
o Filing cabinets  Can be viewed as a repository of data that is
o Spreadsheets defined once and then accessed by various
o Folders users.
o Ledgers
o Lists Database Properties
o Piles of papers on your desk  It is a representation of some aspect of the real
 Because of the mechanical nature of databases, world or a collection of data elements (facts)
they have terrific power to manage and process representing real world information.
the information they hold. This can make the  A database is logical, coherent and internally
information they house much more useful for consistent.
your work.  A database is designed, built and populated
with data for a specific purpose.
Key Terms:  Each data item is stored in a field.
concurrency: the ability of the database to allow  A combination of fields makes up a table. For
multiple users access to the same record without example, each field in an employee table
adversely affecting transaction processing contains data about an individual employee.

data element: a single fact or piece of information Database Management System (DBMS)
 A collection of programs that enables users to
data inconsistency: a situation where various copies create and maintain databases and control all
of the same data are conflicting access to them.
 The primary goal of a DBMS is to provide an
data isolation: a property that determines when environment that is both convenient and
and how changes made by one operation become efficient for users to retrieve and store
visible to other concurrent users and systems information

data integrity: refers to the maintenance and Key Terms


assurance that the data in a database are correct database: a shared collection of related data used
and consistent to support the activities of a particular organization

data redundancy: a situation that occurs in a database management system (DBMS): a


database when a field needs to be updated in more collection of programs that enables users to create
than one table and maintain databases and control all access to
them
table: a combination of fields  In some cases, data redundancy still exists
Characteristics and Benefits of a Database to improve system performance, but such
1. Self-describing nature of a database system redundancy is controlled by application
 A database system is referred to as self- programming and kept to minimum by
describing because it not only contains the introducing as little redundancy as possible
database itself, but also metadata which when designing the database.
defines and describes the data and 6. Data Sharing
relationships between tables in the  The integration of all the data, for an
database. This information is used by the organization, within a database system has
DBMS software or database users if many advantages:
needed. o Allows for data sharing among
 This separation of data and information employees and others who have access
about the data makes a database system to the system.
totally different from the traditional file- o Gives users the ability to generate more
based system in which the data definition is information from a given amount of
part of the application programs. data than would be possible without
2. Insulation between program and data the integration.
 In the file-based system, the structure of 7. Enforcement of integrity constraints
the data files is defined in the application  Database constraint – a restriction or rule
programs so if a user wants to change the that dictates what can be entered or edited
structure of a file, all the programs that in a table.
access that file might need to be changed as  Data uniqueness
well. o Such as the primary key
 In the database approach, the data o Ensures that no duplicates are entered.
structure is stored in the system catalogue o Constraints can be simple (field based)
and not in the programs. Therefore, one or complex (programming).
change is all that is needed to change the
structure of a file. This insulation between Advantages
the programs and data is also called 1. Restriction of unauthorized access
program-data independence.  Not all users of a database system will have
3. Support for multiple views of data the same accessing privileges.
 A database supports multiple views of data. o Read-only
 A view is a subset of the database, which is o Read and write
defined and dedicated for particular users 2. Data independence
of the system.  The system data descriptions or data
 Multiple users in the system might have describing data (metadata) are separated
different views of the system. Each view from the application programs.
might contain only the data of interest to a  This is possible because changes to the data
user or group of users. structure are handled by the database
4. Sharing of data and multiuser system management system and are not
 Current database systems are designed for embedded in the program itself.
multiple users. That is, they allow many 3. Transaction Processing
users to access the same database at the  A database management system must
same time. include concurrency control subsystems.
 This access is achieved through features This feature ensures that data remains
called concurrency control strategies. These consistent and valid during transaction
strategies ensure that the data accessed are processing even if several users update the
always correct and that data integrity is same information.
maintained. 4. Provision for multiple views of data
5. Control of Data Redundancy  A DBMS permits many users to have access
 In the database approach, ideally, each data to its database either individually or
item is stored in only one place in the simultaneously. It is not important for users
database.
to be aware of how and where the data
they access is stored. Data management/information management
 Task of managing organizational data and data
5. Backup and Recovery facilities processing functions.
 Methods that allow you to protect your
data from loss. Databases
 The database system provides a separate  Where data resources of an organization are
process, from that of a network backup, for usually stored.
backing up and recovering data.
 If a hard drive fails and the database stored Database systems
on the hard drive is not accessible, the only  Integrated collections of databases along with
way to recover the database is from a users who share the databases, personnel who
backup. design and manage databases, techniques for
 If a computer system fails in the middle of a designing and managing databases, and
complex update process, the recovery computer systems to support them.
subsystem is responsible for making sure  The main goal of database systems is to provide
that the database is restored to its original managers with information so that they can
state. make effective decisions about how to run the
organization.
Key Terms:
concurrency control strategies: features of a Data
database that allow several users access to the  Numbers, words, names, and other symbols
same data item at the same time that can be stored in a computer system.

data type: determines the sort of data permitted in Information


a field, for example numbers only  Useful data

data uniqueness: ensures that no duplicates are Elements of Database Systems


entered 1. People
 Can be divided into two groups:
database constraint: a restriction that determines o Those who use information provided by
what is allowed to be entered or edited in a table the system
o Those who design, develop, and manage the
metadata: defines and describes the data and system itself
relationships between tables in the database
Database administrators
 People responsible for the design,
read and write privileges: the ability to both read
development, and administration of
and modify a file database systems.
Information analysts/Database
read-only access: the ability to read a file but not analysts
make changes  Personnel responsible for developing
database systems.
self-describing: a database system is referred to as  Information analysts work closely
self-describing because it not only contains the with users of information to
database itself, but also metadata which defines carefully define information
and describes the data and relationships between requirements and to structure
tables in the database these requirements into a logical
form.
view: a subset of the database  Database analysts use database
technology to design systems
James F. Courtney and David B. Paradice's satisfying those requirements.
Database Systems for Management: "Chapter 1: 2. Computer Hardware and Software
Introduction to Database Systems"
 Form the technological foundation fo standard reports are produced periodically
database systems. (weekly, monthly, or annually) for use by middle
 Can be separated into two groups: managers to support tasks such as budget
o Applications software decisions and personnel assignments.
o Database Management Systems  Decision support systems are designed to
(DBMS) – commercial software provide information for managerial decision
packages designed to provide the basis making in cases where the decision is not
for building database systems. clear-cut (ill-structured or semi-structured
3. Databases in DSS jargon).
 The integrated database is defined in the
schema, which describes all the data items Effective Systems and Efficient Systems
and relationships in the entire database.  Effective systems provide correct, current
 Each programmer's individual view of the information that is relevant to the decision at
database is defined in a subschema. hand.
 A database is an integrated collection of  Efficient systems, on the other hand, perform a
shared files. task in a cost-effective manner
4. Database Planning and Design Techniques
 The first step in converting to a database Objectives of Database Systems
approach should be the development of 1. Access Flexibility
o A master plan that specifies in general  Allows for easy retrieval of selected items in
terms the various applications and a database and presentation of that data in
databases to be included in the overall a variety of formats.
system  Query language – designed to perform
o A schedule for detailed design and tasks with a few simple commands.
implementation of these applications  Structured Query Language (SQL) –
and databases. standard query language for relational
 Detailed database design consists of three database systems.
major phases:  Data manipulation language (DML) –
o Information requirements analysis is commands that may be embedded in
work done with users to define application programs to add, retrieve, or
information needs. change data values.
o Logical design is the development of  Report generators – languages designed to
schema and subschema definitions. create printed reports.
o Physical design establishes exactly how  Screen generators – help analysts write
the data will be organized and stored routines to create forms on a terminal
on the storage devices. screen.
2. Data Integrity
Database Systems and other Organizational  Ensures that data values are correct,
Information systems consistent, and current.
 Transaction processing systems form the 3. Data security
bottom of the pyramid and are the lifeblood  Protect data from unauthorized access and
systems of the organization because they from accidental or intentional damage or
support the processing of "production" data-- destruction.
for example, for inventory maintenance,  Recovery is the process of using logs and
accounts receivable and payable, and other backup copies to recreate a damaged
accounting functions. database.
 Management information systems are in the  Other security facilities include passwords
middle of the pyramid and are used primarily by for individual users that allow different
Middle management to control the types of access to the database (for
organization. These systems derive much of example, read only or read and write), and
their information by summarizing and passwords for databases, data records, and
abstracting data from transaction processing even individual data items.
systems. They tend to be report oriented;
4. Data Independence and the ANSI/SPARC to the conceptual level. One user may wish
Model to change or add a user view, which
 Has two dimensions: changes the conceptual level, but this
o Logical data independence should have no impact on other users and
o Physical data independence their views.
 American National Standards
Institute/Standards Planning and
Requirements Committee (ANSI/SPARC) –
three-level architecture of database 5. Reduced Data Redundancy
systems:  Data redundancy is storage of the same
o External level piece of data in more than one place in the
 Uppermost level in the architecture computer system.
 Closest to the users of the system  Data redundancy leads to:
and refers to the way users view o Problems of data integrity – because
the data – printed reports, forms, the same data are duplicated in several
or other documents. places, it must be changed in each place
 User view – data as thought of by it occurs; otherwise inconsistent data
an individual user or group of users values will arise.
with similar needs o Processing inefficiencies – updating the
o Conceptual level same data requires extra processing
 Middle level in the architecture time.
 Represents the union of all the user  Two approaches to reduce data
views at the external level. redundancy:
 An integrated view or schema of o Data Structure Diagram/Bachman
the entire database Diagram
 At this level, the representation of  Pointers – “point to” associated
data still reflects human views of records in other files.
data. o Relational Model – data elements are
 The database at this level is shown in tables called relations.
described in a logical schema. 6. Data Shareability
o Internal level/physical level  Allows different users or user groups to use the
 Actual representation of data same (non-redundant) data.
within the computer system and 7. Data Relatability
the methods used to access the  Ability to establish logical relationships
data. between different types of records, usually
 Specifies how the data are in different files.
represented physically in the 8. Standardization
storage devices of the machine.  Refers to the need for common definitions
 In a system with physical data of data items, in terms of both the precise
independence, the conceptual level schema definition of a data item name and its
is independent of changes in the internal or storage format in the database.
physical level; that is, the way the data are  Most database management systems
actually stored or accessed in the system provide a data dictionary facility to define
can be changed without requiring a change data item names and to state the internal
in the logical schema. The database storage format of the data items in the
management system is responsible for database.
insulating the conceptual level from  Synonyms/aliases – when more than one
changes in the physical level by providing name is used to refer to the same data
means of translating physical item.
representations into conceptual 9. Personnel Productivity
representations.  The modification of existing programs to
 In a system with logical data independence, satisfy changing information requirements
the external level is independent of changes is referred to as program maintenance.
oIt uses "Parent Child Relationships" to
Disadvantages of the Database Approach create links between record types.
 Database approach is expensive at first. o It does this by using trees.
 Multi-user packages are complex and often o However, it is only able to cope with
have extensive memory requirements. one tree. As well, there can only be one
 Additional costs arise because database parent per child, and no relationships
programming may be more complex than file- among the child records are possible.
oriented programming.  Has a very structured form.
o Allows no links between layers in
different branches of the tree.
The User’s View o It is easy to use for adding, updating
 Database systems exist to support the needs of and deleting records.
information users. The needs of users are thus  Advantages of the database:
paramount in the development of an effective o it is easy to design
system. Different users of a database system o it is cheap to maintain
have different needs and different perspectives o it is easy to use
on the system and the information and data it o as all data are stored in a common
provides. database, it implies data sharing and
 In an integrated database environment, it is security can be enforced
unusual for any one user to need access to o a certain degree of data independence
every item in the database. Thus the can be maintained
perspective of users is often limited. The  Shortcomings of the database:
primary concern of each user is to get the o The hierarchical database is inflexible to
information he or she needs. Information information.
analysts are concerned with ensuring that the o Relationships are difficult to implement
information requirements of users are satisfied.
in a hierarchical model.
Thus the objective of information analysts is to
o Extensive programming activities
provide an effective system—one that does the
required. Navigation inside the tree is
right thing—by supplying the information
complicated.
required to make decisions.
o Difficult to solve the problem of single
 Database analysts are concerned with designing
child with multiple parents
databases that provide the required
o Difficult to navigate through: with the
information efficiently. Effective, efficient
exception of the root record, all records
organizational information is best provided
have to be accessed through the
through integrated, shared database systems.
parent.
In database management, the different
o Alteration of data is difficult due to
perspectives of users are referred to as user
rules governing the relationship of
views.
records.
o It is simple and cannot perform many-
1.2 Database Environments
to-many correspondence.
The Computer Revolution: "Database Models" 2. Network Databases
 Types of networks:
Database Models: o Wide area Network (WAN): a
1. Hierarchical Databases communication network that covers a
 Oldest database models. wide geographical area. i.e. long
o Developed out of the 1950's and 60's distance telephone companies
Information Management Systems. o Metropolitan Area Network (MAN): a
 Stores data in a series of records. communication network that covers a
o These records have a set of field values
city or suburb. i.e. local telephone
attached to them.
companies and many cell phone
o All instances of a specific record are
companies
collected together as a "record type".
o Local Area Network (LAN): connects accommodate a user's ad hoc request for
computers and devices in a limited selected data.
geographic area. i.e. universities  Most every business database management
o Home Area Network (HAN): wired system (DBMS), including Oracle, DB2, SQL
cable or wireless networks. i.e. Server, MySQL, etc., is a relational DBMS
(RDBMS)
computers, printers, VCR, TV, home
 Properties of Relational Databases:
security systems.
o Values are atomic
o Personal Area Network (PAN): slightly
 Columns in a relational table are
different from HAN, because it doesn't not repeating groups, this property
use wires, it uses short range wireless ultimately simplifies data
technology. i.e. cell phones, PDA's, MP3 manipulation logic.
players, bluetooth. o Each column and row has a unique
 Charles Bachman invented the network name
database model.  The columns and rows are not
 Very similar to the hierarchical model. distinctive by position and
o Instead of using a single-parent tree therefore they must have a name
hierarchy, the network model uses set which is distinct from the rest of the
table in order to identify them.
theory to provide a tree-like hierarchy
o Each row is unique
with the exception that the child tables
 No two rows are identical which
were allowed to have more than one
ensures that every row has
parent. significance without duplication.
o Allowed the network database model to o The sequence of columns and rows is
support many relationships. insignificant
 The look is more like several trees that  This allows the information in the
share branches. table to be retrieved with ease and
o Children can have multiple parents and without and disruption to the data
parents can have multiple children. within the table. A
 Benefits of Network Database Model:  Allows many more users of the
o General Services table because the data is not
confined to one format and is not
o Research Service
changed when information is added
o Technology Services
or removed.
3. Relational Database Model o Column values are of the same kind
 Relational database  Each value within a specific column
o A database system in which any holds the same type of information
database file can be a component of and is of the same units as all the
more than one of the database's tables. other data in the chart.
o A database system in which the  Keys
database is organized and accessed o The tool to unlock access to tables.
according to the relationships between Knowledge of the key enables us to
data items without the need for any locate specific records, and cross the
consideration of physical orientation relationships between tables.
and relationship. o Certain fields may be designated as
 Relationships between data items
keys, which means that searches for
are expressed by means of tables.
specific values of that field will use
 A database that maintains a set of separate,
indexing.
related files (tables), but combines data
elements from the files for queries and o Candidate key
reports when required.  Any field, or combination of fields,
 Concept was developed in 1970 by Edgar that uniquely identifies a record.
Codd, whose objective was to The field/s of the candidate key
must contain unique values (if the  An object-oriented database uses software
values were duplicated, they would where little chunks are written within the
be no longer identify unique database files.
records), and cannot contain a null  An object has two parts:
value. o data that could be audio, video or
o Primary key graphics
 The candidate key that has been o instructions on what action to be taken
chosen to identify unique records on the data.
in a particular table.  Object-oriented database has the capability
o Foreign key to handle from small files to very large files
 Reference to a key in another of information. It is easy to read and more
table. A relationship between two efficient when it comes to managing a lot of
tables is created by creating a data.
common field to the two tables.  Virtual object database
 Allow us to ensure what is called 7. Multidimensional Database
"referential integrity". This means a  View data as multidimensional cubes that
foreign key that contains a value are particularly well suited for data analysis.
must refer to an existing record in  Multidimensional models categorize data
the related table. either as facts with associated numerical
4. Object-Oriented Database measures or as textual dimensions that
 General characterize the facts.
o Object-oriented database  Multidimensional data models have three
 "Uses 'objects,' software written in important application areas within data
small, reusable chunks, as elements analysis:
within database files" o Data warehouses are large repositories
 Multimedia Database that integrate data from several sources
o Uses multiple forms of information in an enterprise for analysis.
content and information processing o Online analytical processing (OLAP)
(e.g. text, audio, graphics, animation, systems provide fast answers for
video, interactivity). queries that aggregate large amounts of
Can store more types of data than a detail data to find overall trends.
relational database. o Data mining applications seek to
 Hypertext Database discover knowledge by searching
o Any object, whether it be a piece of semiautomatically for previously
text, a picture, or a film, can be linked unknown patterns and relationships in
to any other object. multidimensional databases.
o Useful for organizing large amounts of  When is a Multidimensional Database used?
disparate information, but they are not o If you have a large volume of data
designed for numerical analysis.cc and/or categories and complex
5. Hypermedia Database relationships between them
 Allow media files to be queried and used as 8. Hybrid Database Model
a tool to develop an understanding of your  A combination of two or more database
originally searched question. types and models.
 The goal of a hypermedia data base is to  An emerging type of hybrid database is the
minimize error while saving space; obtained hybrid XML/relational database, which is a
by linking to files via 'tags' or searchable type of database that can store and receive
text, then upon entry into the link (after a both XML and relational data. Both of the
search is completed) the files format types of data can be accessed via quires and
program is ran. the databases can work together in a single
6. Object-relational application.

Databases and the Web


 How web databases work?
o First a user visits a site and fills out a query  The entity has attributes that
box, i.e. a search box, and follows through represent properties such as an
with an "enter" or click to submit the query. employee’s name, address and
o Next once the query is submitted the web birthdate.
server converts the information submitted  Relationship – represents an
by the user into a database query which association among entities; for
gets sent to a database server for example, an employee works on
processing. many projects. A relationship exists
o Lastly the database server looks up the between the employee and each
query and sends back results to the query project.
to the web sever or middleware, which is 2. Record-based Logical Data Models
software that ties a web server and a  Provide concepts users can understand but
database two separate applications, that are not too far from the way data is stored
gets converted to HTML that can be in the computer.
displayed back to the user.  Types:
o Relational model
 Represents data as relations
o Network model
 Represents data as record types
Middleware  Represents a limited type of one to
 Software used to connect two otherwise many relationship called a set type
separate applications, such as a Web server and o Hierarchical model
a database management system.  Represents data as a hierarchical
 Web database applications often use tree structure
middleware written as scripts or sections of  Each branch of the hierarchy
code written in a programming language; such represents a number of related
as Java, C, or Perl; that are executed by another records
program.
 There are different types of scripts such as: CGI Key Terms:
scripts (common gateway interface), ASPs hierarchical model: represents data as a
(active server pages), and PHP scripts (PHP hierarchical tree structure
hypertext preprocessor).
instance: a record within a table
Micro-Targeting
 The use of analytical tools to identify groups of network model: represents data as record types
voters to target during a political campaign.
relation: another term for table
Adirenne Watt and Nelson Eng's Database Design:
"Chapter 4: Types of Data Models" and "Chapter 5: relational model: represents data as relations or
Data Modeling" tables

Types of Data Models: set type: a limited type of one to many relationship
1. High-Level Conceptual Data Models
 Provide concepts for presenting data in Data Modelling
ways that are close to the way people  Steps in the process of database design:
perceive data. 1. Data Modelling
 Example: o Considered to be a high-level and
o Entity relationship model abstract design phase, also referred to
 Uses main concepts like entities, as conceptual design.
attributes and relationships. o The aim of this phase is to describe:
 Entity – represents a real-world  The data contained in the database
object such as an employee or a (e.g., entities: students, lecturers,
project. courses, subjects)
 The relationships between data - Semantic information (e.g., business
items (e.g., students are supervised rules)
by lecturers; lecturers teach - Security and integrity information
courses)  Consider a database as a collection of
 The constraints on data (e.g., entities (objects) of various kinds
student number has exactly eight  Are the basis for identification and high-
digits; a subject has four or six units level description of main data objects;
of credit only) they avoid details
2. The data items, the relationships and the  Are database independent regardless of
constraints are all expressed using the the database you will be using
concepts provided by the high-level data o Internal models – the three best-known
model. models of this kind are the relational data
3. Database Design model, the network data model and the
o Two sub-steps: hierarchical data model. These internal
 Database logical design – defines a models:
database in a data model of a  Consider a database as a collection of
specific DBMS. fixed-size records
 Database physical design – which  Are closer to the physical level or file
defines the internal database structure
storage structure, file organization  Are a representation of the database as
or indexing techniques. seen by the DBMS.
o These two sub-steps are database  Require the designer to match the
implementation and operations/user conceptual model’s characteristics and
interfaces building steps. constraints to those of the selected
implementation model
Data Model  Involve mapping the entities in the
 Collection of concepts or notations for conceptual model to the tables in the
describing data, data relationships, data relational model
semantics and data constraints. o Physical models
 Most data models also include a set of basic  Are the physical representation of the
operations for manipulating data in the database
database.  Have the lowest level of abstractions
 Are how the data is stored; they deal
Degrees of Data Abstraction with
 Models in order of decreasing level of - Run-time performance
abstraction: - Storage utilization and compression
o External models - File organization and access methods
 Represent the user’s view of the - Data encryption
database  Are the physical level – managed by the
 Contain multiple different external operating system (OS)
views  Provide concepts that describe the
 Are closely related to the real world as details of how data are stored in the
perceived by each user computer’s memory
o Conceptual models
 Provide flexible data-structuring Data Abstraction Layer
capabilities  External Model
 Present a “community view”: the logical o End user’s view of the data
structure of the entire database o Requires that the designer subdivide a set
 Contain data stored in the database of requirements and constraints into
 Show relationships among data functional modules that can be examined
including: within the framework of their external
- Constraints models (e.g., human resources versus
sales).
 Conceptual Model  Logical schema – conceptual design of
o First model created the database done on paper or a
o Independent of both software and whiteboard
hardware o Physical data independence
 Internal Model  The immunity of the internal model to
o Once a DBMS is selected, you can then changes in the physical model
implement it.  The logical schema stays unchanged
o Here you create all the tables, constraints, even though changes are made to file
keys, rules, etc. organization or storage structures,
o Often referred to as the logical design storage devices or indexing strategy.
 Physical Model  Physical data independence deals with
o The way the data is stored on disk hiding the details of the storage
structure from user applications.
Schemas
 Schema Key Terms:
o An overall description of a database conceptual model: the logical structure of the
o Usually represented by the entity entire database
relationship diagram (ERD)
conceptual schema: another term for logical
 There are many subschemas that represent
schema
external models and thus display external views
of the data.
data independence: the immunity of user
 Below is a list of items to consider during the
applications to changes made in the definition and
design process of a database.
organization of data
o External schemas: there are multiple
o Multiple subschemas: these display multiple
data model: a collection of concepts or notations
external views of the data
for describing data, data relationships, data
o Conceptual schema: there is only one. This
semantics and data constraints
schema includes data items, relationships
and constraints, all represented in an ERD.
data modelling: the first step in the process of
o Physical schema: there is only one
database design
Logical and Physical Data Independence database logical design: defines a database in a
 Data Independence data model of a specific database management
o The immunity of user applications to system
changes made in the definition and
organization of data. database physical design: defines the internal
 Data abstractions expose only those items that database storage structure, file organization or
are important or pertinent to the user. indexing techniques
 Complexity is hidden from the database user.
 Data independence and operation entity relationship diagram (ERD): a data model
independence together form the feature of describing the database showing tables, attributes
data abstraction. and relationships
 There are two types of data independence:
o Logical data independence external model: represents the user’s view of the
 The ability to change the logical database
schema, without changing the external
schema or user view external schema: user view
 Changes to the logical schema (e.g.,
alterations to the structureof the internal model: a representation of the database as
database like adding a column or other seen by the DBMS
tables) should not affect the function of
the application (external views).
logical data independence: the ability to change THE DATABASE SYSTEM MASTER PLAN
the logical schema without changing the external  Contents of the database system master plan
schema should include a statement of organizational
goals and objectives, an organization chart,
logical design: where you create all the tables, entity diagrams showing the major relationships
constraints, keys, rules, etc. among entities in the enterprise, modules or
subsystems to be implemented as part of the
logical schema: a conceptual design of the database database system, the costs and benefits
done on paper or a whiteboard, much like expected to be associated with the system, and
architectural drawings for a house a schedule for implementing each module.
1. Organizational Goals and Objectives
operating system (OS): manages the physical level  Two aspects of the organizational
of the physical model environment should be considered in the
master plan:
physical data independence: the immunity of the o Organizational goals and objectives
internal model to changes in the physical model o The manner in which the enterprise is
structured
physical model: the physical representation of the  Organizational goals and objectives are
database important to database system design; many
critical information needs may be derived
schema: an overall description of a database from them.
 When possible, goals and objectives should
be stated in numeric terms, so that progress
James F. Courtney and David B. Paradice's toward those goals can be measured.
Database Systems for Management: "Chapter 2: Instead of saying that the goal is to increase
Elements of Database Systems" sales, for example, one might say that the
goal is to increase sales by 10 percent.
“Effective” System  The database system should assist
 A system that "does the right thing" by managers of the organization in measuring
providing the information necessary to run the the level of goal attainment and in steering
organization. the organization toward its goals.
Structure  Thus the database system master plan
 Parts of a system and how these parts interact. should begin with a brief statement of
Module organizational goals and objectives and how
 Describe a major element of the overall the database system will measure progress
database system, not to a piece of toward goals.
programming code. 2. Organizational Structure
Database System Master Plan  Second feature of the organizational
 Lays out the ultimate structure and contents of environment that should be included in the
the database system--and does so before work master plan.
begins on the system itself.  It is important to consider the structure of
Entity the organization because the database
 Any object, tangible or intangible, about which system will surely be required to support
the organization wishes to store data. the flow of information between various
 Have attributes, such as name, color, and price. units or divisions of the enterprise.
Navigation Path  The information flow usually follows
 Arrows pointing left or right to indicate the organizational channels between superior
route. and subordinate units.
Pointers  For this reason, the database system is said
 Arrows in databases indicating where the to be "superimposed" on the structure of
program should look on the system's storage the organization. It is convenient to include
devices to find certain records. an organizational chart and a brief
description of the function of each of the
organizational units in the database system  It must also ensure that anticipated benefits
master plan. outweigh these costs.
3. Entity Charts  The value of benefits of database systems is
 Entities and their relationships are initially much more difficult to estimate than costs.
defined by working with users, who must be
able to specify their information needs. Techniques and Procedures in a Database
 Represent the major entities and Environment
relationships among them to give an overall  Database Design Techniques
view of the database structure. o The process of database design consists of
 Relationships in the diagram are of three three major phases:
types:  An information-requirements analysis
o One-to-one (abbreviated 1:1) phase
relationship  A logical design phase
 One instance of an entity of a given  Physical design phase.
type is associated with only one  Information-Requirements Analysis and User
member of another type Views
 Single-headed arrows are used to o Information-requirements analysis
represent a "one" relationship in  Involves working with users to define
the direction of the arrow. their information needs in detail.
o One-to-many (1:M) relationship  Concerned with information as users
 One instance of a given type of see it; that is, information is viewed in
entity is related to many instances terms of the way it appears in
of another type. documents, on terminal screens, or
 Double-headed arrows are used to even in images in the user's mind.
represent "many" relationships.  Representations of information and
data at this level are referred to as
o Many-to-many (M:M) relationship "user views."
 Many entities of one type are  Information-requirements analysis is
associated with many instances of the first and most important phase of
another type. the database design process. It is the
4. Entity Groups, Database System Modules, and most important phase because the
Schedules ultimate effectiveness of the system
 The master plan should describe the major depends on how accurately the
pieces or modules of the system to be information requirements and user
developed, how these modules will fit views are specified initially.
together into an integrated structure, and a  Specifications of user information
schedule for detailed design and requirements feed the entire design
development of each module. process and determine the ultimate
 It may be possible to define these modules form and content of the database
based on the number and strength of the system.
relationships in the entity diagram.  Poor specifications result in a system
5. Cost and Benefits that does not satisfy user needs and
 Management of the organization should, may lead to costly redesign, or even to
and probably will, view the development of cancellation of the project.
a database system as an investment that  Logical Design
must pay for itself; that is, the benefits o Once the various views have been defined
derived from using information provided by and specifications developed, they must be
the system must outweigh the cost of coordinated and organized into an
developing it. integrated, cohesive system. This process is
 The organization must have a realistic referred to as logical design.
picture of the anticipated cost to make sure o Consists of three steps:
that funds are available to develop and  Developing a data model for each user
operate the system. view
 Integrating the entities, attributes, and o Relational approach
relationships into a composite logical  Describes databases using tables with
schema that describes the database for special characteristics
that module in terms unrelated to the o Relations
software package being used  Tables
 Transforming the logical schema into a
software schema expressed in the Software
language of the chosen database  Three different kinds of software involved in
management package. most database systems:
 Physical Design o Database management packages
o The last step of the database design o Operating systems
process. o Applications programs
o Involves converting the software schema  Applications programs gain access to the
into a form implementable with the database through the database management
organization's particular hardware, system. Most database management packages
operating system, and database use the basic access methods of the host
management system. operating system to perform the necessary
o Involves designing navigation paths, input-output operations on the data files
deciding which records to place in nearby themselves (some packages support their own
portions of the storage devices, access methods).
determining the size of physical records on Database Management Systems
storage devices and buffer areas in main  Minimum components:
memory to hold records, and implementing o Data dictionary for cataloging all the data
integrity and security requirements. items in the system
o Data definition language for further
Other Database Techniques and Procedures describing the software schema and user
 Many other procedures and techniques in views
addition to those for database design exist in a o One or more query languages suitable for
database environment. These include end-users as well as programmers
procedures for analyzing, implementing, and o Data manipulation language for use by
operating systems, designing and documenting programmers
programs, and training users. o Report generator language for efficient
 Among the tasks involving these procedures are programming of management reports
collecting data to be entered into the system, o Features to support data integrity, security,
performing manual edit checks to ensure the privacy, and recovery
integrity of the data before it is entered,  Data Dictionary
actually entering data, running programs o Used to maintain standard definitions of all
necessary to update the database and generate data items within the scope of the database
reports from it, logging changes to the system.
databases, making backup copies of the o The purpose of the data dictionary is to
database so that it can be reconstructed if
enforce standard definitions of the data
accidentally damaged or destroyed, and
resources of the organization.
assuring that security procedures are followed.
 Definitions include a precise description
of the meaning of a data item name and
Databases
a precise description of how values of
 Integrated, shared collections of files. each data item are stored in the
 Databases are stored physically on the storage computer system.
devices of the organization's computer system. o Functions of a good data dictionary include:
The way the data is organized and stored on
 Maintaining standard user definitions of
these devices is referred to as its physical
the precise meaning of data items and
organization.
standard computer definitions giving
 People think of data in terms of its logical formats and data types
organization.
 Maintaining cross-reference lists of data report generators. In many cases, these
items used by applications programs features make the programming much easier
and applications programs using a given than with the conventional file approach.
data item
 Providing standard definitions of data Hardware
items to applications programs when
requested to do so.
o Passive dictionaries simply maintain user
and computer definitions of data items.
o Active dictionaries include an interface to
applications programs to support features
such as generating record and field (data
item) descriptions for application programs.
 Data Definition Languages
o Used to translate the logical schema into a
software schema for the database
management package in use.
o Two languages defined by CODASYL
committees:
 The schema DDL for specifying the
composite schema
 The subschema DDL for specifying user
views or data subsets of the schema
o Structured Query Language (SQL)
 Adopted as the industry standard for
relational languages.
 Many relational packages use SQL,
which has features for describing the
relations of a relational database.
 Query Languages
o Designed to give end-users direct access to
the database.
o One type of fourth-generation language
(4GL).
 First generation is machine (binary)
language
 The second is assembly language
 The third is programming languages
such as C++, SQL, JAVA, or VISUALBASIC

Database Applications Software


 The major difference between database
applications software and conventional
applications software is the use of special
statements for data insertion, removal,
retrieval, and modification in database systems.
These data manipulation commands are usually
embedded in a host language such as JAVA or
C++.
 Other differences in database programming and
conventional programming in high-level
languages include different ways of describing
data and data relationships, and the use of

You might also like