CH-1 (I) Introduction To DBMS
CH-1 (I) Introduction To DBMS
Database System Concepts - 6th Edition 1.2 ©Silberschatz, Korth and Sudarshan
Database Management System (DBMS)
Generally DBMS contains information about a particular enterprise
Collection of interrelated data
Set of programs that provide a way to store and retrieve the
data that is both convenient and efficient to use
Database System Concepts - 6th Edition 1.3 ©Silberschatz, Korth and Sudarshan
Database Management System (DBMS)
1.1 Database Applications(cont…)
Sales: customers, products, purchases information
Online retailers: online order tracking, customized
recommendations and maintain online product evaluations
Manufacturing: for managing supply chain and tracking
production items in factories, inventory of items in warehouse,
orders.
Human resources: for information about employee, salaries,
tax deductions
Telecommunications for keeping of records of calls made,
generating monthly bills, storing information about
communication networks.
Hospitals for maintaining records of patient
Database System Concepts - 6th Edition 1.4 ©Silberschatz, Korth and Sudarshan
Database Management System (DBMS)
1.1 Database Applications(cont…)
Digital Libraries for management and delivery of large textual
and multimedia data.
E-commerce- integration of heterogeneous information
sources for business activity such as online shopping, booking
of holiday, consulting doctors
Databases can be very large. it touch all aspects of our lives
Goals of DBMS
Storing and retrieving data efficiently and effectively
To ensure security and avoid the problem
Concurrency control
Database System Concepts - 6th Edition 1.5 ©Silberschatz, Korth and Sudarshan
Database Management System (DBMS)
Function of DBMS
Defining:- specifying data types, structures and constraints for
the data
Constructing:- process of storing data itself on some storage
medium
Manipulating:- querying database to retrieve specific data and
updating database.
Sharing:- allow multiple user and program to access database
concurrently.
Protection:- protect system against software and hardware
failures and also provide security protection against malicious
user/access.
Maintaining:- should allow database to evolve as requirements
change over time.
Database System Concepts - 6th Edition 1.6 ©Silberschatz, Korth and Sudarshan
1.2 Purpose of Database System
Drawbacks of using file systems to store data
Data redundancy and inconsistency
Multiple file formats, duplication of information in different
files
Difficulty in accessing data
Need to write a new program to carry out each new task
Data isolation — multiple files and formats made writing new
application program to retrieve data.
Integrity problems
Integrity constraints (e.g., account balance > 0) become
“buried” in program code rather than being stated explicitly
Hard to add new constraints or change existing ones
Database System Concepts - 6th Edition 1.7 ©Silberschatz, Korth and Sudarshan
(Cont.)
Database System Concepts - 6th Edition 1.11 ©Silberschatz, Korth and Sudarshan
Cont ….
Instance – the actual content of the database at a particular point
in time
Analogous to the value of a variable
Physical Data Independence
The ability to modify the physical schema without changing the
logical schema
Applications depend on the logical schema
In general, the interfaces between the various levels and
components should be well defined so that changes in some
parts do not seriously influence others.
Database System Concepts - 6th Edition 1.12 ©Silberschatz, Korth and Sudarshan
1.3.3 Data Models
A collection of conceptual tools for describing
Data, Data relationships
Data semantics and Data constraints
1) Relational model
Use a collection of tables to represent both data and the
relationship among those data.
An example of record based model in which the database is
structured in fixed format records of several types.
2) Entity-Relationship model (mainly for database design)
Use a collection of basic objects, called entity and relationship
among these objects.
Entity is a real world object that is distinguishable from other
objects.
Entity set is a collection of entity.
Database System Concepts - 6th Edition 1.13 ©Silberschatz, Korth and Sudarshan
Cont….
3) Object-based data models (Object-oriented and Object-relational)
Object-oriented data model is seen as extending of E-R model
with the notions of encapsulation, method and object identity.
Object-Relation model combines the concept of object oriented
and relational data model.
4) Semi-structured data model (XML)
Permits the specification of data where individual data items of
the same type may have different sets of attributes.
5) Other older models: tied closely to the underlying implementation
and complicated task of modeling.
Network model
Hierarchical model
Database System Concepts - 6th Edition 1.14 ©Silberschatz, Korth and Sudarshan
Relational Model
Relational model (Chapter 2)
Columns
Example of tabular data in the relational model
Rows
Database System Concepts - 6th Edition 1.15 ©Silberschatz, Korth and Sudarshan
Database Design?
Is there any problem with this design?
Database System Concepts - 6th Edition 1.20 ©Silberschatz, Korth and Sudarshan
The Entity-Relationship Model
Models an enterprise as a collection of entities and relationships
Entity: a “thing” or “object” in the enterprise that is
distinguishable from other objects (person, bank accounts)
and Described by a set of attributes.
Entity set: a set of all entities of the same type
Relationship: an association among several entities
Represented diagrammatically by an entity-relationship diagram:
Database System Concepts - 6th Edition 1.21 ©Silberschatz, Korth and Sudarshan
1.6 Storage Management
Storage manager is a program module that provides the interface
between the low-level data stored in the database and the
application programs and queries submitted to the system.
The storage manager is responsible to the following tasks:
Interaction with the file manager
Efficient storing, retrieving and updating of data
Issues:
Storage access
File organization
Indexing and hashing
Database System Concepts - 6th Edition 1.24 ©Silberschatz, Korth and Sudarshan
1.7 DBMS Architecture
1) Physical DBMS Architecture
Defines the software components used to process and enter data,
and how these software components are related and
interconnected.
Database System Concepts - 6th Edition 1.25 ©Silberschatz, Korth and Sudarshan
Cont ….
ELEMENTS OF A DATABASE MANAGEMENT SYSTEM
The major components of a DBMS are explained below:
DML Precompiled: It converts DML statement embedded in an
application program to normal procedure calls in the host language.
DDL Compiler: The DDL compiler converts the data definition
statements into a set of tables.
File Manager: Manages the allocation of space on disk storage and the
data structure used to represent information stored on disk.
Database Manager: Convert user's queries coming directly via the
query processor or indirectly via an application program from the user's
logical view to the physical file system. Also performs the tasks of
enforcing constraints to maintain the consistency and integrity of the data
as well as its security.
Database System Concepts - 6th Edition 1.26 ©Silberschatz, Korth and Sudarshan
Cont ….
ELEMENTS OF A DATABASE MANAGEMENT SYSTEM
Query Processor: used to interpret the online user's query and
convert it into an efficient series of operations in a form capable of
being sent to the data manager for execution. It uses the data
dictionary to find the structure of the relevant portion of the
database and uses this information in modifying the query and
preparing an optimal plan to access the database.
Database Administrator: Responsible for overall management of
data resources in an organization including maintaining corporate
wide data definitions and standards.
Data Dictionary: Keeping a track of all the available names that
are used and the purpose for which they were used becomes
more and more difficult.
Database System Concepts - 6th Edition 1.27 ©Silberschatz, Korth and Sudarshan
Database System Internals
Database System Concepts - 6th Edition 1.28 ©Silberschatz, Korth and Sudarshan
1.7 Database Users and Administrators
There are four different types of database-system users,
differentiated by the way they expect to interact with the system:
DBA (Database Administrator): is responsible for authorizing to
access the database, to monitoring its use and for acquiring
software and hardware resources as needed.
Generally DBA are do the following tasks:
Schema definitions
Storage structure and access method definitions
Schema and physical organization modifications
Granting authorization for data access
Routine maintainance( regularly backing up database,
ensure enough free disk space)
Database System Concepts - 6th Edition 1.29 ©Silberschatz, Korth and Sudarshan
Cont…
Database Designer: responsible to select appropriate structure
for represent and store the data. Before select the
structure ,Designer will meet all the database users and find out all
the requirements which they want to fulfill. After collect all the
requirement it comes with their design and structure and this work
is completed before database implementation.
End Users: These are:
1) Casual Users: These are the users who communicate with
the database for little period of time. They are occasionally
used the database. So these are the temporary users.
2) Parametric Or Naive Users: These are the users who
communicate with the database for a regular period. Their main
job is to constantly querying and updating the database using
standard queries
Database System Concepts - 6th Edition 1.30 ©Silberschatz, Korth and Sudarshan
Cont…
3) Sophisticated End Users: These are engineers, scientists,
business analysts who are familiarize with the database and
when they want to use the database, they used it regularly and
when they don’t want then they are temporally used .
4)Stand alone users: These are the users who maintain their
personal database using ready made software which is
available in the market easily and provide the menu based
interface through which they can easily used the database.
System Analysts and Application Programmers: System analysts
find out the requirements of parametric end users and develop all
the analysis for canned transaction through which they can meet
all the requirements of parametric users. Application programmers
implement these analysis as programs. These are especially
Software engineers.
Database System Concepts - 6th Edition 1.31 ©Silberschatz, Korth and Sudarshan
End of Chapter 1
Database System Concepts - 6th Edition 1.32 ©Silberschatz, Korth and Sudarshan