Professional Documents
Culture Documents
UNIT-1
www.company.com
CS201-DBMS Dept of CSE
UNIT-1
• Students will able to design the databases for any real time
Outcomes::
applications.
www.company.com
CS201-DBMS Dept of CSE
UNIT-1
www.company.com
CS201-DBMS Dept of CSE
Contents
www.company.com
CS201-DBMS Dept of CSE
data
• A data mean known facts or raw facts that can be recorded
and that have implicit meaning.
Topic 1
• For example, consider the names, telephone, numbers, and
Introduction to addresses of the people you know. You may have recorded
Database
Systems this data in an indexed address book, you may have stored it
on a hard drive, using a personal computer and software such
as Microsoft Access, or Excel.
www.company.com
CS201-DBMS Dept of CSE
Database
• Database is a large collection of related data that
Topic 1 can be stored generally describes activities of an
Introduction to organization.
Database Systems
www.company.com
CS201-DBMS Dept of CSE
Database Properties
•
It is used to store data of an organization.
•
A database is designed and developed for a specific purpose.
Topic 1
•
It has some source from which data is derived and it is
populated with that data.
Introduction to • It can be of any size
Database Systems
• It allows multiple users to share and access database at the
same time.
Eg: - University database which includes students, faculty,
courses & class rooms information along with activities such
as enrolment and teaching courses.
www.company.com
CS201-DBMS Dept of CSE
Database Management System
www.company.com
CS201-DBMS Dept of CSE
Database Management System
www.company.com
CS201-DBMS Dept of CSE
Actions of DBMS
www.company.com
CS201-DBMS Dept of CSE
Actions of DBMS
Introduction to
Database Systems
www.company.com
CS201-DBMS Dept of CSE
Simplified database system
environment
Topic 1
Introduction to
Database Systems
www.company.com
CS201-DBMS Dept of CSE
Database Applications
www.company.com
CS201-DBMS Dept of CSE
Database Applications:
www.company.com
CS201-DBMS Dept of CSE
File System
www.company.com
CS201-DBMS Dept of CSE
File processing processing system
www.company.com
CS201-DBMS Dept of CSE
Drawbacks of File System
3. Data isolation
File System
4. Enforcing Integrity constraints
5. Atomicity problems
7. Security Problems
www.company.com
CS201-DBMS Dept of CSE
Cont ...
www.company.com
CS201-DBMS Dept of CSE
Cont ...
Data Redundancy and Inconsistency:
Atomicity problems:
www.company.com
CS201-DBMS Dept of CSE
Advantages of DBMS
1. Controlling Redundancy
3. Data Security
Advantages of 4. Providing Storage Structures for Efficient Query
DBMS
Processing
8. Report Writers
www.company.com
CS201-DBMS Dept of CSE
Controlling Redundancy
www.company.com
CS201-DBMS Dept of CSE
Data Consistency:
www.company.com
CS201-DBMS Dept of CSE
Data Security
• Some users may be permitted only to retrieve data,
whereas others are allowed to retrieve as well as to
Topic 3 update data.
• The database access is controlled by the DBA.
• He creates the accounts of users and gives rights to
Advantages of access the database.
DBMS • Typically, users or group of users are given usernames
protected by passwords.
• Most of the DBMSs provide the security sub-system,
which the DBA uses to create accounts of users and to
specify account restrictions.
www.company.com
CS201-DBMS Dept of CSE
Providing Storage Structures for Efficient Query
Processing
www.company.com
CS201-DBMS Dept of CSE
Providing concurrency control
www.company.com
CS201-DBMS Dept of CSE
Enforcing Integrity constraints
www.company.com
CS201-DBMS Dept of CSE
Actors of DBMS
Topic 4
DBA, Designers
and End users
www.company.com
CS201-DBMS Dept of CSE
Database Administrator(DBA)
www.company.com
CS201-DBMS Dept of CSE
Responsibilities of DBA
www.company.com
CS201-DBMS Dept of CSE
Responsibilities of DBA
Topic 4 database
www.company.com
CS201-DBMS Dept of CSE
Database Designers
www.company.com
CS201-DBMS Dept of CSE
Database Designers
www.company.com
CS201-DBMS Dept of CSE
End Users
• Stand-alone users
www.company.com
CS201-DBMS Dept of CSE
Casual end users
www.company.com
CS201-DBMS Dept of CSE
Naive or parametric end users
www.company.com
CS201-DBMS Dept of CSE
Sophisticated end users
www.company.com
CS201-DBMS Dept of CSE
Data Models
www.company.com
CS201-DBMS Dept of CSE
Relational Model
• Most commonly used model is the relational model.
• In this model data is organized as two-dimensional tables.
Topic 5 • Each table is called relation.
• The relational model uses a collection of tables to represent
Types of Data both data and the relationships among those data. Each table
Models has multiple columns, and each column has a unique name.
• The relational model is implemented in database where a
relation is represented by a table, a tuple is represented by a
row, and an attribute is represented by a column of the table.
www.company.com
CS201-DBMS Dept of CSE
Entity-Relationship Model
• Entity-Relationship model is based on the notion of real
world entities and relationship among them.
Topic 5 • ER Model is best used for the conceptual design of
database.
Types of Data • ER Model is based on:
Models • Entities and their attributes
• Relationships among entities
www.company.com
CS201-DBMS Dept of CSE
Entity-Relationship Model
Entity
• An entity in ER Model is real world entity, which has some
Topic 5 properties called attributes. Every attribute is defined by its set of
values, called domain.
• For example, in a school database, a student is considered as an
Types of Data entity. Student has various attributes like name, age and class etc.
Models
www.company.com
CS201-DBMS Dept of CSE
Hierarchical Model
• A hierarchical data model is a data model which the data is
organized into a tree like structure.
Topic 5 • First commercial DBMS is based on this model.
• In Hierarchical model data is represented as records and the
Types of Data records organized as collection of trees.
Models • The relationships among the data are represented by links,
which can be viewed as pointers.
www.company.com
CS201-DBMS Dept of CSE
Network Model
Network Model
• In Network model data is represented as records and the
Topic 5 records organized as collection of arbitrary graphs.
• The relationships among the data are represented by links,
Types of Data which can be viewed as pointers.
Models • In network model a record can have any number of parent
records.
www.company.com
CS201-DBMS Dept of CSE
Schemas, Instances, and Database
State
• Database Schema refers to the overall structure of a database.
• The description of a database is called the database schema, which is
Sub topic 5 specified during database design and is not expected to change
frequently
Schema Diagram:
Schema Student
Course
Teacher
www.company.com
CS201-DBMS Dept of CSE
Instance:
www.company.com
CS201-DBMS Dept of CSE
Levels of Abstraction or Three-Schema
architecture:
Topic 6
Three-Schema
architecture
3-Schema
Architecture
www.company.com
CS201-DBMS Dept of CSE
Internal level or internal schema:
• The internal schema uses a physical data model and
describes the complete details of data storage and
Topic 6 access paths for the database.
• It tells us what data is stored in the database and how.
At least the following aspects are considered at this
Three-Schema
level:
architecture
• Storage allocation: B-trees, hashing etc.
• Access paths: specification of primary and secondary
keys, indexes and pointers and sequencing..
www.company.com
CS201-DBMS Dept of CSE
Conceptual level or conceptual schema
www.company.com
CS201-DBMS Dept of CSE
External level or External View:
www.company.com
CS201-DBMS Dept of CSE
Data Independence
www.company.com
CS201-DBMS Dept of CSE
Physical data independence:
www.company.com
CS201-DBMS Dept of CSE
Logical data independence:
www.company.com
CS201-DBMS Dept of CSE
DBMS architecture
Topic 7 divided in to
www.company.com
CS201-DBMS Dept of CSE
Architecture Diagram
Topic 7
DBMS
architecture
Dbms Architecture
www.company.com
CS201-DBMS Dept of CSE
Query Processor Components
The Query Processor Components include:
DDL interpreter:
Topic 7 • It interprets DDL statements and converts them in to a set
tables which are saved in the data dictionary
DBMS architecture DML compiler:
• It translates DML statements into low-level instructions
that are understood by the Query Evaluation Engine.
• It also optimizes the DML Queries for efficient execution
by the Query Evaluation Engine.
Query evaluation engine:
• It executes low-level instructions generated by the DML
compiler and produces results.
www.company.com
CS201-DBMS Dept of CSE
Storage Manager Components
www.company.com
CS201-DBMS Dept of CSE
Storage Manager Components
File manager:
Topic 7 • It manages the allocation of disk-space for the
DBMS architecture
storage of DBMS files.
Buffer manager:
• It is responsible for fetching data from disk storage
into main memory buffers for processing, and then
writing the updated data back onto the disk.
www.company.com
CS201-DBMS Dept of CSE
Data Components
Data files:
• Which store the database itself.
Topic 7 Data dictionary:
• It is a metadata file, which stores the database schema. It
DBMS architecture stores metadata about the structure of the database.
Indices:
• It can provide fast access to data items. Like the index in
this textbook, a database index provides pointers to those
data items that hold a particular value.
Statistical data:
• It stores the statistical information about processing of
previous queries. This information is used by the Query
Processor to optimize the queries.
www.company.com
CS201-DBMS Dept of CSE
CLASSIFICATION OF DATABASE
MANAGEMENT SYSTEMS
Several criteria are normally used to classify DBMSs are
1. Based on data model
Topic 8 2. No of users supported by the System
3. Number of sites over which the database is distributed
CLASSIFICATION 4. Cost
OF DATABASE
MANAGEMENT 5. Types of access path options
SYSTEMS 6. Based on purpose
www.company.com
CS201-DBMS Dept of CSE
1.Based on Data Model:
www.company.com
CS201-DBMS Dept of CSE
2.No of users supported by the System::
www.company.com
CS201-DBMS Dept of CSE
3. Number of sites over which the database is
distributed
Centralized vs. distributed
• A DBMS is centralized if the data is stored at a single computer
Topic 8 site. A centralized DBMS can support multiple users, but the
DBMS and the database themselves reside totally at a single
computer site.
CLASSIFICATION
OF DATABASE
• A distributed DBMS (DDBMS) can have the actual database
MANAGEMENT
and DBMS software distributed over many sites, connected by a
SYSTEMS computer network.
www.company.com
CS201-DBMS Dept of CSE
4. Cost
www.company.com
CS201-DBMS Dept of CSE
5. Access path
www.company.com
CS201-DBMS Dept of CSE
6. General-purpose vs. special-purpose
www.company.com
CS201-DBMS Dept of CSE
centralized and client/server
architectures for dbms
3-tier Architecture:
www.company.com
CS201-DBMS Dept of CSE
centralized and client/server
architectures for dbms
www.company.com
CS201-DBMS Dept of CSE
centralized and client/server
architectures for dbms
• Database (Data) Tier − At this tier, the database
resides along with its query processing languages. We
also have the relations that define the data and their
constraints at this level.
• Application (Middle) Tier − At this tier reside the
application server and the programs that access the
database. For a user, this application tier presents an
abstracted view of the database. End-users are unaware
of any existence of the database beyond the
application. At the other end, the database tier is not
aware of any other user beyond the application tier.
Hence, the application layer sits in the middle and acts
as a mediator between the end-user and the database.
www.company.com
CS201-DBMS Dept of CSE
centralized and client/server
architectures for dbms
www.company.com
CS201-DBMS Dept of CSE
Assignment Questions:
www.company.com
CS201-DBMS Dept of CSE
THANK YOU
www.company.com
CS201-DBMS Dept of CSE