0% found this document useful (0 votes)
257 views48 pages

Dbms Module 1

A database is a collection of related data organized in a way that facilitates data searches. A database management system (DBMS) is software that allows users to create, store, organize, and retrieve data from one or many databases. A DBMS provides tools to manage databases, control access to data, and contains a query language to retrieve information.
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
257 views48 pages

Dbms Module 1

A database is a collection of related data organized in a way that facilitates data searches. A database management system (DBMS) is software that allows users to create, store, organize, and retrieve data from one or many databases. A DBMS provides tools to manage databases, control access to data, and contains a query language to retrieve information.
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 48

Overview of DBMS

 Database Defined::
A database is a collection of data
which can be used:
 alone, or
 combined / related to other data
 to provide answers to the user’s question
 It is A collection of related data organized
in a way that facilitates data searches.
Example of a Student Database
Databases
Before the Use of Computers
 Data was stored in:
– books
– ledgers
– card files
– folders
– file cabinets
– or simply in people’s heads!?
Computers make the process of
storing and managing data easier
The Database Approach
 Database Management System
– software application which allows you to
create, store, organize, and retrieve data from
a single database or many databases.
– Example: MS Access
DATABASE MANAGEMENT SYSTEMS

 A DBMS is a collection of programs which


 provide management of databases
 control access to data
 contain a query language to retrieve
information easily
Cont……..
 Database Design
 It is important to design the database in such a
way that:

 A specific item can be reached easily


(maximum guarantee that the desired record will be
reached)
 The database can respond to the user’s
different questions easily
(necessary relationships are provided)
DATABASE MANAGEMENT SYSTEMS

 The database occupies minimum storage space


(choosing data types and how to express a certain
concept is important)
 The database contains no unnecessary data
(storing the gross salary is enough, the net salary
can be calculated from the gross salary)
 Data can be added and updated easily
without causing mistakes
(no data redundancy)
A Database Contains
the Following:
 Tables
– how entities are represented in a database,
where each row is a record and each column
a field.
 Fields
– individual pieces of information
 Record
– collection of related fields within one entity
Sample Data Table
Key Database Issues
and Activities
 Entering and Querying Data
 Creating Database Reports
 Data Structure
 Data Type
Entering Data
 Data Entry:
– process of getting information into a database
– possible methods of data entry:
 Data Entry Professional, Electronic Files, Historical
Records, or Web Based (Forms)
Querying Data
 Querying:
– how we get information from a database
 Structured Query Language (SQL):
– most common language used to interface with
databases
– Example:
SELECT DISTINCTROW STUDENT_ID, GRADE
FROM GRADES
WHERE GRADE = “A”
ORDER BY STUDENT_ID;
Querying Data continued
 Query By Example (QBE)
– enables you to fill out a grid, or template, in
order to construct a description of the data
you would like to retrieve.
Cont….
Creating Database Reports
 Report:
– A compilation of data from the database that
is organized and produced in a printed format.
– Typically produced on paper, but also can be
displayed on-screen.
– Example: Quarterly Sales Report
Data Structure
 Database has two parts:
– Data
– Data Structure: how the data is organized.
 Data Model:
– representation of entities and their
relationships to the real world
 Primary Key:
– a unique identifier in the database
– one or more fields
Data Type
 Data Type:
– each field in the database needs to be of a
certain type
– Examples: text, number, dates
 Data Dictionary:
– a document (often published online) prepared
by the database designers to assist users in
data entry.
Data Dictionary Example:
Students Table

Primary Key Field Name Field Type


Field Length
yes Student ID Number 9
no Last Name Text 20
no First Name Text 15
Data processing Environment
 data base - consists of data elements and
the relationships between them
 it is a collection of data organized to
– service many applications at the same time
– by storing and managing data so that they
appear to be in one location
 DBMS - database management system
Cont……….
 special software to create and maintain a
database and allow individual business
applications to extract data they need
without having to create separate files
 DBMS promotes independence between
data, programs, and the database
Limitation of Data processing
Environment
 1.data redundancy
– presence of duplicate data in multiple files
– error prone
 2. lack of flexibility
– traditional file system cannot deliver ad hoc
reports
– information needed for ad hoc reports is
somewhere in the system, but too
difficult/expensive to easily retrieve
Cont……

 3. poor security
– because there is little control or management
of data, access to and distribution of
information is not controlled
 4. lack of data sharing and availability
– due to lack of control over data resource, not
easy to share data - pieces of information is in
different files in different parts of organization
Components of DBMS
Environment
Cont…….
 Hardware
– Can range from a PC to a network of computers.
 Software
– DBMS, operating system, network software (if
necessary) and also the application programs.
 Data
– Used by the organization and a description of this
data called the schema.
 Procedures
– Instructions and rules that should be applied to the
design and use of the database and DBMS.
 People
Advantages of DBMS
 Control of data redundancy
 Data consistency
 More information from the same amount of data
 Sharing of data
 Improved data integrity
 Improved security
 Enforcement of standards
 Economy of scale
Cont…..
 Balanced conflicting requirements
 Improved data accessibility and
responsiveness
 Increased productivity
 Improved maintenance through data
independence
 Increased concurrency
 Improved backup and recovery services
Data Independence
 Ability to modify a schema definition at one level
without affecting a schema definition in the next
higher level

 Logical Data Independence


 – Refers to protection of external schemas to
changes in conceptual schema.
 – Conceptual schema changes (e.g.
addition/removal of entities).
 – Should not require changes to external
schema or rewrites of application programs.
Data independence
 Physical Data Independence

 – Refers to immunity of conceptual schema to


 changes in the internal schema.
 – Internal schema changes (e.g. using different
 file organizations, storage structures/devices).
 – Should not require change to conceptual or
 external schemas.
Data Abstraction
 The major purpose of a database system
is to provide users with an abstract view
of the system. The system hides certain
details of how data is stored and created
and maintained is called data abstraction
Three levels of data abstraction
External
 – Users' view of the database.
 – Describes that part of database that is
relevant to a particular user.
Conceptual Level
 – Community view of the database.
 – Describes what data is stored in
database and relationships among the
data.
Cont….
 Internal Level (physical level)
 – Physical representation of the database
on the computer .
 – Describes how the data is stored in the
database.
Cont……
   
Cont….
 Physical level (internal level) describes how a
record (e.g., customer) is stored.
 Logical level: describes data stored in database,
and the relationships among the data.
type customer = record
name : string;
street : string;
city : integer;
end;
 View level (External level) : application programs
hide details of data types. Views can also hide
information (e.g., salary) for security purposes.
Three-level Architecture
3rd level of abstraction
External Schemas customizations
External External External of the conceptual
schema to the
Schema 1 Schema 2 ... Schema n needs of various
(Savings A/C) (Checking A/C) (IRA A/C/) classes of users

2nd level Conceptual what data are stored,


of abstraction Schema what relationships, constraints exist

1st level Physical


how the data are physically stored
of abstraction Schema

actual data
Data models
 Data Modeling:
A model that describes in an
abstract way how data are represented in
a business organization, an information
system, or a database management
system.
Defining The Types Of Models
 Business Data Model describes the data
using business terms and semantics. A Business
Entity is the artifact within a Business
Information Model.

 • Storage Model describes the private


representation of the data as it exists in
persistent storage e.g. database. This is the
Storage Form.

 • Collection Model describes the structure of


the data as it is received. Each feed may
maintain only a fragment of a Business Entity.
This is the Collection Form
Cont……….
 Retrieval Model describes the data as it is used by a
consuming application. All Retrieval Forms are read-only
views of the Business Entity they are based on. This is
the Retrieval Form.

 • The Enterprise Data Model combines the Business


Information Model and the Retrieval Data Models to
provide a view of what the data is and where it is used.

 • All the models together form the Integrated Data


Model that describes the entire corporate universe
coherently.
Cont…..
Architecture of a DBMS
Schema
Modifications Queries Modifications

Database
System
Query
Processor
DBMS operation
Software
Subsystem
Storage
Manager

Data
Data Definition
(Metadata)
Overview of conventional
data models
 The Hierarchical Model

 The Net work Model

 The Relational Model


The Hierarchical Model

 Records in parent entities can have many


child records, but each child can have only
one parent.
Parent

Child
The Network Model
 In this case you can have multiple children
and parents
Parents

Children
The Relational Model

– A good relational database design


eliminates unnecessary data
duplications and is, therefore, easier
to maintain
– Relationship: joining two tables on a
common field
Example………..

Relationship
People who with database
 Basically variety of people are associated
with creation and use of database.
 Ex-:: There are database implementers
who build dbms s/w and end users who
wish to store and use data in a DBMS.
 Database implementers work for vendors
like—IBM and Oracle etc..
 End users come from a diverse and
increasing number of fields.
Cont….
 Two other classes people are associated with
a DBMS-::
application programmers
database administrator
 application programmers develop packages
that facilitate data access for end users, who
are usually not computer professionals.
 Application programs should ideally access
data through external schema
Cont….
 Database administrator
here a personal database is typically
maintained by the individual who owns it and
use it.
 DBA is responsible for many critical task like…..
design of conceptual & physical schema.
security and authorization.
data availability and recovery from failures.
database tuning.

You might also like