0% found this document useful (0 votes)
1 views

database management sysyems

The document provides an overview of Database Management Systems (DBMS), including definitions, applications, advantages, and basic terms related to databases. It discusses the architecture of DBMS, the three levels of data abstraction (internal, conceptual, and external), and the importance of data independence. Additionally, it outlines the types of database users and emphasizes the significance of data integrity, security, and backup services in managing databases.

Uploaded by

yoju1907
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
1 views

database management sysyems

The document provides an overview of Database Management Systems (DBMS), including definitions, applications, advantages, and basic terms related to databases. It discusses the architecture of DBMS, the three levels of data abstraction (internal, conceptual, and external), and the importance of data independence. Additionally, it outlines the types of database users and emphasizes the significance of data integrity, security, and backup services in managing databases.

Uploaded by

yoju1907
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 37

Unit-1

Database
System
Architecture
 Looping
Outline
• Introduction of DBMS
• Applications of DBMS
• Advantages of DBMS
• Three levels ANSI SPARC
database system
• Data Abstraction in DBMS
• Mappings and data independence
• Database users and DBA
• Database system architecture
Introduction to DBMS
Section - 1
What is Database Management System
(DBMS)?
 Data - Fact that can be recorded or stored
 e.g. Person Name, Age, Gender and Weight etc.
 Database - Collection of logically related data
 e.g. Books Database in Library, Student Database in University etc.
 Management - Manipulation, Searching and Security of data
 e.g. Viewing result in VTOP website, Searching exam papers in VIT website etc.
 System - Programs or tools used to manage database
 e.g. SQL Server Studio Express, Oracle etc.
 DBMS - A Database Management System is a software for creating and
managing databases.
 Database Management System (DBMS) is a software designed to
define, manipulate, retrieve and manage data in a database.
 e.g. MS SQL Server, Oracle, My SQL, SQLite, MongoDB etc.

4
Applications of DBMS
Section - 2
Applications of DBMS
 DBMS is a computerized record-keeping system.
 DBMS is required where ever data need to be stored.
 E-Commerce (Flipkart, Amazon, Shopclues, eBay etc...)
 Online Television Streaming (Hotstar, Amazon Prime etc...)
 Social Media (WhatsApp, Facebook, Twitter, LinkedIn etc...)
 Banking & Insurance
 Airline & Railway
 Universities and Colleges/Schools
 Library Management System
 Human Resource Department
 Hospitals and Medical Stores
 Government Organizations

Exerci Write down any five applications of DBMS


se other than above.

6
Advantages of DBMS
Section - 3
Reduce data redundancy (duplication)

Computer Civil

Addres Mobil Subje Addres Mobil Subje


Emp_Name Emp_Name
s e ct s e ct
Prof. Ajay Prof. Ajay
Rajkot 1234 PPS Rajkot 1234 PPS
Shah Shah
Database management Same data is stored
system can remove such at
data redundancy by four different
storing data centrally. places.

Addres Mobil Subje Addres Mobil Subje


Emp_Name Emp_Name
s e ct s e ct
Prof. Ajay Prof. Ajay
Rajkot 1234 PPS Rajkot 1234 PPS
Shah Shah
Electrical Mechanical

8
Remove data inconsistency

Computer Civil

Addres Mobil Subje Addres Mobil Subje


Emp_Name Emp_Name
s e ct s e ct
Prof. Ajay 6789 Prof. Ajay
Rajkot 1234 PPS Rajkot 1234 PPS
Shah Shah
Same data having
Database different state
management system (values)
can keep data in
consistent state. Mobile no is
changed
Addres Mobil Subje Addres Mobil Subje
Emp_Name Emp_Name
s e ct s e ct
Prof. Ajay 6789 Prof. Ajay
Rajkot 1234 PPS Rajkot 1234 PPS
Shah Shah
Electrical Mechanical

9
Data isolation
 Data are scattered in various files.
File -
 Files may be in different formats. 1 Addres Mobil Subje
 Difficult to retrieve the appropriate data.Emp_Name
Prof. Ajay
s e ct
Rajkot 1234 PPS
Shah
DBMS allow us to access (retrieve) File -
appropriate data easily. 2
Emp_Name Post Salary Load

Data isolation is a property that determines Prof. Ajay Lectur 50,00


15
Shah er 0
when and how changes made by one
operation become visible to other concurrent File -
users and systems. 3 Teachin Knowled Rati
This issue occurs in a concurrency situation. Emp_Name
g ge ng
Prof. Ajay Excellen
Good 9
Shah t

10
Guaranteed atomicity
 Atomicity: Either transaction execute 0% or 100%.

Sum of both
account before
transfer is 3000

Person Person
A Transfer 500 B
Account Account
A Step 1 : Debit 500 from B
Bal : Account A Bal : Sum of both
Transactio
2000 Step 2Sum of both
: Credit 500 into 1000 account is
n is failed account 2500
Account B
after transfer is so
3000 inconsistent
11
Allow to implement integrity constraints

Addres Subje
Emp_Name Mobile_No
s ct
Prof. Ajay 98765432
Rajkot Should contain
PPS
exact 10
Shah 10
digits

Student_Na
Branch Backlog SPI
me
Nirav Patel Rajkot 0 8.5
Should be between 0
to 10

DBMS allows us to implement such business rules in


our database..

12
Sharing of data among multiple users
Want to
access
Computer Civil

Addres Mobil Subje Addres Mobil Subje


Emp_Name Emp_Name
s e ct s e ct
Prof. Ajay Prof. Ajay
Rajkot 1234 PPS Rajkot 1234 PPS
Shah Shah
Want to Database management
access system allows more than
one user to access same
data simultaneously.

Addres Mobil Subje Addres Mobil Subje


Emp_Name Emp_Name
s e ct s e ct
Prof. Ajay Prof. Ajay
Rajkot 1234 PPS Rajkot 1234 PPS
Shah Shah
Electrical Mechanical

13
Restricting unauthorized access to data

File -
1 Addres Mobil Subje
Emp_Name
s e ct
Prof. Ajay
Rajkot 1234 PPS
Shah Wants
to Faculty
File -
access of
2
Emp_Name Post Salary Load other
college
Prof. Ajay Lectur 50,00
15
Shah er 0
File -
3 Teachin Knowled Rati
Emp_Name
g ge ng
Prof. Ajay Excellen
Good 9
Shah t
DBMS prevents unauthorized user to
access data.
14
Providing backup and recovery services

Provides facilities to backup and restore the database in


case of failure.

15
Advantages of DBMS (Summary)
 Reduce data redundancy (duplication)
 Avoids unnecessary duplication of data by storing data centrally.
 Remove data inconsistency
 By eliminating redundancy, data inconsistency can be removed.
 Data isolation
 A user can easily retrieve proper data as per his/her requirement.
 Guaranteed atomicity
 Either transaction executes 0% or 100%.

16
Advantages of DBMS (Summary)
 Allow implementing integrity constraints
 Business rules can be implemented such as do not allow to store amount less
than Rs. 0 in balance.
 Sharing of data among multiple users
 More than one users can access same data at the same time.
 Restricting unauthorized access to data
 A user can only access data which is authorized to him/her.
 Providing backup and recovery services
 Can take a regular auto or manual backup and use it to restore the database
if it corrupts.

17
Basic Terms
Section - 4
Basic terms
 Data
 Data is raw, unorganized facts that need to be processed.
 Example: Marks of students
 Student_1 = 50/100, Student_2 = 25/100.
 Information
 When data is processed, organized, structured or presented in a given context
so as to make it useful, it is called information.
 Example: Result of students (Pass or Fail)
 Student_1 = Pass, Student_2 = Fail.

19
Basic terms (cont…)
 Metadata
 Metadata is data about data.
 Data such as table name, column name, data type, authorized user and user access
privileges for any table is called metadata for that table.

Facul
ty Addres Subje
Emp_Name Mobile_No
s ct
Prof. Ajay 98765432
Rajkot PPS
Shah 10
 Metadata of above table is:
 Table name such as Faculty
 Column name such as Emp_Name, Address, Mobile_No, Subject
 Datatype such as Varchar, Decimal
 Access privileges such as Read, Write (Update)

20
Basic terms (cont…)
 Data dictionary
 A data dictionary is an information repository which contains metadata.
• Table Name – Faculty
• Column Name – EmpName, Address, Mob,
Subject, Salary
• Datatype – Varchar, Decimal
• Access Privileges – Read, Write (Update)
 Data warehouse
 A data warehouse is an information repository which stores data.

Facul
ty Addres Subje
Emp_Name Mobile_No
s ct
Prof. Ajay 98765432
Rajkot PPS
Shah 10
Prof. Ajay 01234567
Surat DBMS
Patel 89
Exerci Why data dictionary and data warehouse are stored in the
se different places?
21
Basic terms (cont…)
 Field
 A field is a character or group of characters that have a specific meaning.
 E.g, the value of Emp_Name, Address, Mobile_No etc are all fields of Faculty table.
Facul
ty Addres Subje
Emp_Name Mobile_No Fields
s ct
Prof. Ajay 98765432 Prof. Ajay Rajkot 9876543
Rajkot PPS
Shah 10 Shah 210
Prof. Ajay
 Record 01234567
/ Tuple
Patel
Surat
89
DBMS
 A record is a collection of logically related fields.
 E.g, the collection of fields (Emp_Name, Address, Mobile_No, Subject) forms a record
for the Faculty.
Prof. Ajay 98765432 Record /
Rajkot PPS
Shah 10 Tuple
Prof. Ajay 01234567
Surat DBMS
Patel 89

22
3 Levels ANSI SPARC
Database System
Section - 5
3 Levels ANSI SPARC Database System

User User User


1 2 3
How data are View
View 1 View 2 View 3
viewed by each Level
users?

Conceptua
What data are stored Logic
l
and al
Level
What relationships Level
exist?

How the data are Internal Physi


actually stored on Level cal
storage devices? Level

Database

24
3 Levels ANSI SPARC Database System
 Internal level (Physical level)
 It describes how a data is stored on the storage device.
 Deals with physical storage of data.
 Structure of records on disk - files, pages, blocks and indexes and ordering of records
 Internal view is described by the internal schema.
 Conceptual level (Logical level)
 What data are stored and what relationships exist among those data?
 It hides low level complexities of physical storage.
 For Example, STUDENT database may contain STUDENT and COURSE tables which
will be visible to users but users are unaware about their storage.
 Database administrator works at this level to determine what data to keep in the
database.
 External level (View level)
 It describes only part of the entire database that an end user concern or how data
are viewed by each user.
 Different user needs different views of the database, so there can be many views in a
view level abstraction of the database. Used by end users and application
programmers. 25
3 Levels ANSI SPARC Database System: Example
We are storing student information in a
student table.
User User User
User just interact with system with the help of
1 2 3
GUI. View
View 1 View 2 View 3
Users are not aware of how and what the data Level
is stored.
Records can be described as fields and
attributes along with their data types, their Conceptua
relationship among each other can be l Logic
logically implemented. Level al
Programmers generally work at this level. Level
Records can be described as blocks of
storage (bytes, gigabytes, terabytes etc.) in
Internal Physi
memory.
Level cal
These details are often hidden from the
Level
programmers.

Database

26
Data Abstraction in DBMS
 Database systems are made-up of complex data structures.
 To ease the user interaction with database, the developers hide internal
irrelevant details from users.
 This process of hiding irrelevant details from user is called data
abstraction.

27
Mapping and Data Independence
Want to access some
data
User User User
1 2 3
View
View 1 View 2 View 3
Level

Request
Process of transforming requests and results
Conceptua Logic
between the three levels is called mapping. l al
Level Level

Ability to modify a schema definition in one


level without affecting a schema definition in Internal Physi
the next higher level. Level cal
Level

Result
Database

28
Types of Data Independence
 Physical Data Independence
 Physical Data Independence is the ability to modify the physical schema without
requiring any change in logical (conceptual) schema and application programs.
 Modifications at the internal levels are occasionally necessary to improve
performance.
 Possible modifications at internal levels are changes in file structures, compression
techniques, hashing algorithms, storage devices, etc.
 Logical Data Independence
 Logical data independence is the ability to modify the conceptual schema without
requiring any change in application programs.
 Modification at the logical levels is necessary whenever the logical structure of the
database is changed.
 Application programs are heavily dependent on logical structures of the data they
access. So any change in logical structure also requires programs to change.

29
Types of Database
Users
Section - 6
Types of Database Users
 Naive Users (End Users)
 Unsophisticated users who have zero knowledge of database system
 End user interacts to database via sophisticated software or tools
 e.g. Clerk in bank
 Application Programmers
 Programmers who write software using tools such as Java, .Net, PHP etc…
 e.g. Software developers
 Sophisticated Users
 Interact with database system without using an application program
 Use query tools like SQL
 e.g. Analyst
 Specialized Users (DBA)
 User write specialized database applications program
 Use administration tools
 e.g. Database Administrator

31
Role of DBA
(Database
Administrator)
Section - 7
Role of DBA
 Schema Definition
 DBA defines the logical schema of the database.
 Storage Structure and Access Method Definition
 DBA decides how the data is to be represented in the database & how to
access it.
 Defining Security and Integrity Constraints
 DBA decides on various security and integrity constraints.
 Granting of Authorization for Data Access
 DBA determines which user needs access to which part of the database.
 Liaison with Users
 DBA provide necessary data to the user.

33
Role of DBA
 Assisting Application Programmer
 DBA provides assistance to application programmers to develop application
programs.
 Monitoring Performance
 DBA ensures that better performance is maintained by making a change in the
physical or logical schema if required.
 Backup and Recovery
 DBA backing up the database on some storage devices such as DVD, CD or
magnetic tape or remote servers and recover the system in case of failures,
such as flood or virus attack from this backup.

34
Database System
Architecture
Section - 8
Database System Architecture
Naive Application Sophisticated Database
user programmer user administrator
writ
uses uses uses
e
Application Application Query Administration
interfaces program tool tool
Translates
Interprets
DML
DDL
Compiler DML DDL statements
Executes low
statements
Deals with
and linker queries interpreter into low level
Application intolevel
a set of
execution of
instructions
instructions
program DML compiler DDL tables
that andquery
the DML
and organizer generated
containing
statements by
object code Query evaluation evaluation
Query DML compiler.
metadata
engine engine
processor
understands
Buffer File Authorization and Transaction
manager manager integrity manager manager
Storage
Manages
Fetches data
allocation of manager Provides
Preserves
Checks the
from disk storage
space on disk interface
atomicity and
authority of
to memory
storage for between low-
To provide
being usedfaster Indices Data dictionary userscontrols
to access
Disk storage level data stored
concurrency
data and
access to data To To
store statistical and application
Data Statistical data store integrity
To storeitems
user data information about the program or
metadata constraints
data queries

36
Thank
You

You might also like