2. Unit 1
Introduction - Database and database users; Characteristics of the
database approach; Different people behind DBMS; Implications of
database approach; Advantages of using DBMS; When not to use DBMS.
Database System Concepts and Architecture - Data models; Schemas
and instances; DBMS architecture and data independence; Database
languages and interfaces; The database system environment;
Classification of DBMS.
3. What is Data?
Data is nothing but facts and statistics stored.
it's raw and unprocessed.
Data becomes information when it is processed, turning it into
4. What is database
A database is a collection of related data
used to retrieve, insert and delete the data efficiently.
It is also used to organize the data in the form of a table, schema, views,
and reports, etc.
A database system is designed to be built and populated with data for a
5. What is DBMS?
DBMS stands for
Database Management System.
DBMS = Database + Management System.
Database is a collection of data and Management System is a set of
programs to store and retrieve those data.
DBMS is a collection of inter-related data and set of programs to store &
access those data in an easy and effective manner.
6. What is the need of DBMS?
Database systems are basically developed for large amount of data.
When dealing with huge amount of data, there are two things that
require optimization: Storage of data and retrieval of data.
According to the principles of database systems, the data is stored in
such a way that it acquires lot less space as the redundant data
(duplicate data) has been removed before storage.
Ex: banking system
8. Fast Retrieval of data: Along with storing the data in an optimized and
systematic manner, it is also important that we retrieve the data quickly
when needed. Database systems ensure that the data is retrieved as
quickly as possible.
11. Database Users
Database users are the one who really use and take the benefits of
There will be different types of users depending on their need and way
of accessing the database.
They can be categorized into:
1.Actors on the Scene
2.Actors behind the Scene
12. 1. Actors on the scene
The persons whose jobs involve the day to day use of the large database are
called actors on the scene.
2. Database Designers:
3. End users:
4. System analysts
5. Application programmers:
13. Database administrator
Database administrator (DBA) responsible for:
• Authorizing access to the database
• Coordinating and monitoring its use
• Acquiring software and hardware resources
• Tuning the DBMS for best performance
Installing and upgrading the DBMS Servers
Design and implementation:
Migrate database servers:
Backup and Recovery
14. Database designer
Database designer responsible for:
Identifying the data to be stored
Choosing appropriate structures to represent and store this data
study the requirements of the various users to come up with the design
that meets the requirements.
talk to the perspective users & develop the view for different users meet
their processing requirements
15. End users
Those whose jobs require access to the database
1. Naive or parametric end users
• constant queries and updates
2.Casual end users
They occasionally access the database but they may need different
information each time.
They use a sophisticated database query language to specify their requests
& are typically middle of high level managers or occasional browsers.
3. Sophisticated end users
deep knowledge of database design and DBMS facilities
4. Standalone users
users of personal databases
16. System analysts
Determine requirements of end users
System analyst is responsible for the design, structure and properties of
database. All the requirements of the end users are handled by system
Feasibility, economic and technical aspects of DBMS is the main concern of
They study the requirements of End users specially having users and make
the specifications for canned transactions.
• Implement complex specifications (business logic) as programs
They are the developers who interact with the database by means of DML
These DML queries are written in the application programs like C, C++,
JAVA, Pascal etc.
17. Actors behind the Scene
Actors behind the scene are those are typically not interested in
the database content itself.
They include the following categories:
1. DBMS system designers and implementer .
DBMS system designers and implementers design and implement
the DBMS modules and interfaces as a software package.
2. Tool developers
Tool developers design and implement tools—the software packages
that facilitate database modeling and design, database system design, and
improved performance. Tools are optional packages that are often
3. Operators and maintenance personnel
Operators and maintenance personnel (system administration
personnel) are responsible for the actual running and maintenance of the
hardware and software environment for the database system.
18. Implications of Database
1. Potential for Enforcing Standards
The database approach permits the DBA to define and enforce
standards among database users in a large organization.
Standards can be defined for names and formats of data
elements, display formats, report structures and so on.
Date data must be displayed in dd-mm-yyyy format
Names will be displayed as last name, first name and middle
Currency value has to be displayed up to 2 figures after decimal.
19. 2. Reduced Application Development Time
The main advantage of database approach is that developing a
new application takes a very little time.
Once a database is up and running, less time is required to create
new applications using DBMS facilities.
20. 3. Flexibility to alter the data structures
DBMS allows certain types of changes to the structure of the
database without affecting the stored data and the existing
21. 4. Availability of up-to-date Information
A DBMS makes the database available to all users. When one
user updates a database, all other users can immediately see this
Very much needed in reservation systems, banking databases
22. 5. Economy of scalability
With database approach the organizations can cutoff expenses by
minimizing resources and employees.
Data duplicity is considerably reduced so no need to retain copies
of data files in multiple computer systems.
Data stored in centralized database server will be available to all
24. A number of characteristics distinguish the database approach from the much
older approach of programming with files.
1. Self-describing nature of a database system.
2. data abstraction.
3. multiple views of the data.
4. Sharing of data and multiuser transaction processing.
5. Data Integrity:
6. Data Persistence:
25. Self Describing nature
A database is of self describing nature;
it always describes and narrates itself.
It contains the description of the whole data structure, the constraints and the
It makes it different from traditional file management system in which
definition was not the part of application program.
This definition is stored in the database catalog
These definitions are used by the users and DBMS software when needed.
27. Data abstraction
the data structure is stored in the system catalogue and not in the
Therefore, one change is all that is needed to change the structure of a
This insulation between the programs and data is also called program-
28. Support for multiple views of data
A database supports multiple views of data.
A view is a subset of the database, which is defined and dedicated for
particular users of the system.
Multiple users in the system might have different views of the system.
Each view might contain only the data of interest to a user or group of
29. Sharing of data and multiuser
Allow multiple users to access the database at the same time
Database must include concurrency control system
30. Data integrity
Data integrity is a byword for the quality and the reliability of the data
of a database system.
In a broader sense data integrity includes also the protection of the
database from unauthorized access (confidentiality) and unauthorized
Data reflect facts of the real world.
31. Data Persistence:
Data persistence means that in a DBMS all data is maintained as long as it is
not deleted explicitly.
The life span of data needs to be determined directly or indirectly be the user
and must not be dependent on system features.
Additionally data once stored in a database must not be lost.
Changes of a database which are done by a transaction are persistent.
When a transaction is finished even a system crash cannot put the data in
32. Lesson 4
Advantages of Database Management System
Disadvantages of Database Management System
When not to use db
33. Advantages of Database Management
1. Improved data sharing
An advantage of the database management approach is, the DBMS
helps to 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.
34. 2. Improved data security
The more users access the data, the greater the risks of data security
Corporations invest considerable amounts of time, effort, and money to
ensure that corporate data are used properly.
A DBMS provides a framework for better enforcement of data privacy and
35. 3. 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.
36. 4. Minimized data inconsistency
Data inconsistency exists when different versions of the same data appear in
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.
The probability of data inconsistency is greatly reduced in a properly designed
37. 5. 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.
38. 6. Improved decision making
Better-managed data and improved data access make it possible to generate
better-quality information, on which better decisions are based.
The quality of the information generated depends on the quality of the
Data quality is a comprehensive approach to promoting the accuracy, validity,
and timeliness of the data.
While the DBMS does not guarantee data quality, it provides a framework to
facilitate data quality initiatives.
39. 7. Increased end-user productivity
The availability of data, combined with the tools that transform data into
empowers end users to make quick, informed decisions that can make the
difference between success and failure in the global economy.
40. Disadvantages of Database
Management System (DBMS):
1. Increased costs
one of the disadvantages of dbms is Database systems require
sophisticated hardware and software and highly skilled personnel.
The cost of maintaining the hardware, software, and personnel required
to operate and manage a database system can be substantial.
Training, licensing, and regulation compliance costs are often
overlooked when database systems are implemented.
41. 2. Management complexity
Database systems interface with many different technologies and have a
significant impact on a company’s resources and culture.
The changes introduced by the adoption of a database system must be
properly managed to ensure that they help advance the company’s objectives.
Given the fact that database systems hold crucial company data that are
accessed from multiple sources, security issues must be assessed constantly.
42. 3. Maintaining currency
To maximize the efficiency of the database system, you must keep your system
Therefore, you must perform frequent updates and apply the latest patches
and security measures to all components.
Because database technology advances rapidly, personnel training costs tend
to be significant.
43. 4.Vendor dependence.
Given the heavy investment in technology and personnel training,
companies might be reluctant to change database vendors.
As a consequence, vendors are less likely to offer pricing point
advantages to existing customers, and those customers might be limited
in their choice of database system components.
44. 5. Frequent upgrade/replacement cycles
DBMS vendors frequently upgrade their products by adding new functionality.
Such new features often come bundled in new upgrade versions of the
Some of these versions require hardware upgrades.
Not only do the upgrades themselves cost money, but it also costs money to
train database users and administrators to properly use and manage the new
45. WHEN NOT TO USE A DBMS
More desirable to use regular files for:
• Simple, well-defined applications with no expected changes at all
• Small variety of data and/or small amount of data
• real-time requirements that cannot afford DBMS overhead ,High initial
investment in hardware, software, and training
No multiple-user access to data
47. Data models
DBMS allows a user to specify the data to be stored in terms of a
A data model is a collection of higher level data description
constraints that hides lower level storage details.
It is the collection of concepts that can be used to describe the
structure of a database.
48. Data models are of three types:
1. Object based / High-level data models
2. Record based / Representational data models
3. Physical data model / low-level data models
49. 1) High Level or Conceptual Data Model:
It provides the concepts that are close to the way many users
perceive the data. Conceptual Data Model uses the concepts like
entity, attributes, relationship.
• Entity: It is the real world object.
• Attribute: property of the entity.
• Relationship: Interaction between entities.
50. 2) Representational or Implementation Data Model:
It provides the concepts understood by the end users and not far
from the way data is organized on the computer. It includes the
relational model, hierarchical and network model.
There are 3 types of record based data model. They are:
i. Hierarchical data model.
ii. Network data model.
iii. Relational data model.
51. i. Hierarchical data model
The data is sorted hierarchically, using a downward tree.
This model uses pointers to navigate between stored data.
It was the first DBMS model.
52. ii. Network data model
Like the hierarchical model, this model uses pointers toward
stored data. However, it does not necessarily use a downward
53. iii. Relational data model (RDBMS, Relational database
The data is stored in two-dimensional tables (rows and columns).
The data is manipulated based on the relational theory of
55. 3) Low Level or Physical Data Model:
It provides the concepts that describe the details of how data is
stored in the computer.
Physical Data Model describes the storage of data in the
computer by representing information such as record formats,
record orderings and access path.
Concepts provided by these models are generally meant for
computer specialists, not for typical end users.
56. Schemas, Instances, and
The description of a database is called the database schema, which is
specified during database design
It is not expected to change frequently.
A displayed schema is called a schema diagram
Each object in the schema-such as STUDENT or COURSE-a schema
The data in the database at a particular moment in time is called a
database state or snapshot.
57. It is also called the current set of occurrences or instances in the
Eg. the STUDENT construct will contain the set of individual student
entities (records) as its instances.
59. The Three-Schema DBMS
The goal of the three-schema architecture, is to separate the user
applications and the physical database.
In this architecture, schemas can be defined at the following three
1)The internal level/physical level
2) The conceptual level
3) The external or view level
60. The internal level
. The internal level has an internal schema, which describes the physical
storage structure of the database.
The internal schema uses a physical data model and describes the
complete details of data storage and access paths for the database.
61. Conceptual level
The conceptual level has a conceptual schema, which describes the
structure of the whole database for a community of users.
The conceptual schema hides the details of physical storage structures
and concentrates on describing entities, data types, relationships, user
operations, and constraints.
62. External level
The external or view level includes a number of external schemas or
Each external schema describes the part of the database that a
particular user group is interested in and hides the rest of the database
from that user group.
64. The DBMS must transform a request specified on an external schema
into a request against the conceptual schema, and then into a request
on the internal schema for processing over the stored database.
If the request is a database retrieval, the data extracted from the stored
database must be reformatted to match the user's external view.
The processes of transforming requests and results between levels are
65. Data Independence
Data independence is defined as the capacity to change the schema at
one level of a database system without having to change the schema at
the next higher level.
We can define two types of data independence:
1) Logical data independence
2) Physical data independence
66. Logical data independence
Logical data independence is the capacity to change the conceptual
schema without having to change external schemas or application
We may change the conceptual schema to expand the database (by
adding a record type or data item), to change constraints, or to reduce
the database (by removing a record type or data item).
67. Physical data independence
Physical data independence is the capacity to change the internal
schema without having to change the conceptual schema.
Hence, the external schemas need not be changed as well.
Changes to the internal schema may be needed because some physical
files had to be reorganized
for example, by creating additional access structures-to improve the
performance of retrieval or update.
68. DATABASE LANGUAGES AND
A DBMS must provide appropriate languages and interfaces for
each category of users to express database queries and updates.
Database Languages are used to create and maintain database
Languages can be categorized as data definition
language (DDL), data control language (DCL) and data
manipulation language (DML).
It is a language that allows the users to define data and their
relationship to other types of data.
It is mainly used to create files, databases, data dictionary and
tables within databases.
It is also used to specify the structure of each table, set of
associated values with each attribute, integrity constraints,
security and authorization information for each table and physical
storage structure of each table on disk.
It is a language that provides a set of operations to support the
basic data manipulation operations on the data held in the
It allows users to insert, update, delete and retrieve data from the
The part of DML that involves data retrieval is called a query
DML is used to perform the various manipulations on the
database such as to retrieve, insert, delete, modify etc
73. Data Control Language
DCL statements control access to data and the database using
statements such as GRANT and REVOKE.
A privilege can either be granted to a User with the help of
GRANT statement. The privileges assigned can be SELECT,
ALTER, DELETE, EXECUTE, INSERT, INDEX etc. In addition to
granting of privileges, you can also revoke (taken back) it by using
74. Transaction Control
TCL is used to run the changes made by the DML statement. TCL
can be grouped into a logical transaction.
•Commit: It is used to save the transaction on the database.
•Rollback: It is used to restore the database to original since the
75. DBMS Interfaces:
1. Menu Based Interfaces:
•This Interface provides the user with a list of options called menu
that leads the user through the formulation of a request.
•Query is composed in step by step by picking options from a
menu that is displayed by the system.
•It is often used in browsing interfaces.
76. 2. Form based interface:
•A form based interface displays a form to each user.
•Users can fill out the form entries or certain entries using which
the queries will be created.
•DBMS’s will have the form specification languages that help
programmers to specify such form.
77. 3. Graphical user interface (GUI):
•GUI displays schema to the user in diagrammatic form and user
can specify the request by manipulating the diagram.
•GUI’s use menu and forms.
78. 4. Natural language interface:
•This interface accepts the request in English or some other
•Natural language interface has its own schema and a set of words
to interpret the request.
79. 5. Interfaces for parametric users:
•Parametric users like bank tellers have a small set of operations
that must be performed repeatedly.
•The function keys in a terminal can be programmed to initiate
80. 6. Interfaces for DBA:
•It is the set of privileged commands used by the DBA staff, to
create accounts, grant authorizations etc.
7.Apps for Mobile Devices:
These interfaces present mobile users with access to their data.
For example, banking, reservations, and insurance companies,
among many others, provide apps that allow users to access their
data through a mobile phone or mobile device.
81. Classification of DBMS
DBMS can be classified in various ways:
1. Based on the Data Model
A. Relational data model
The relational Data Model represents a database as a collection of tables, where each table
can be stored as a separate file.
B. Hierarchical data model
In a hierarchical data model, data is organized into a tree like structure.
C. Network data model
The network data model represents data in terms of records and organized into graph like
D. Object relational data model
These add new object storage capabilities to the relational systems at the core of modern
information systems, by encapsulating methods with data structures.
82. 2. Based on the number of Users
A.Single User systems
A single user system supports one user at a time. It is used mainly
in personal computers.
B. Multi User systems
A multiuser system supports multiple users at a time, which is
implemented in most of the computers.
83. 3. Based on the number of Sites on which database is distributed
It contains the database at only one computer site, which can support multiple users.
B. Distributed DBMS
It contains the database and DBMS software stored over many sites connected by network.
It uses the same DBMS software at multiple sites.
D. Federated DBMS (Multiple database system)
The participating DBMS’s are loosely coupled and have a degree of local autonomy.
E. Online transaction processing(OLTP)
These support a large number of concurrent transactions without imposing excessive delays.
84. 4. Based on types of access path
It is a package developed to suit the needs of a particular user,
which cannot be used by other users.
It can be used for any type of application.
85. 5.Based on Cost
Majority of DBMS cost more. Single user low-end system that
works with microcomputers cost relatively lesser between $100