Unit1 dbms

By :
Mrs. V. Gowri,
AP/CSE
Unit 1: Introduction to DBMS
Set of programs to access the data
DBMS contains information about a particular enterprise
DBMS provides an environment that is both convenient and efficient to
use.
Database Applications:
• Banking: all transactions
• Airlines: reservations, schedules
• Universities: registration, grades
• Sales: customers, products, purchases
• Manufacturing: production, inventory, orders, supply chain
• Human resources: employee records, salaries, tax deductions
Databases touch all aspects of our lives
Database Management System (DBMS)
Collection of interrelated data
In the early days, database applications were
built on top of file systems.
Drawbacks of using file systems to store data:
Data redundancy and inconsistency - duplication of
information in different files.
• Uncontrolled duplication of data is undesirable for
following reasons:
Duplication costs time and money to enter data more than
once.
It takes additional storage space thus again increasing
associated costs. It can be avoided by sharing data files.
It may lead to data inconsistency.
Difficulty in accessing data
Need to write a new program to carry out each new
task.
Purpose of Database System
• Data isolation — multiple files and formats.
• When data is isolated in separate files, it is more difficult to
access data and to ensure that data is correct.
• Also, the structure of file depends on application
programming language. Thus the direct incompatibility of
such files makes it difficult to process jointly.
• Integrity problems
Integrity constraints (e.g. account balance > 0) become part
of program code
Hard to add new constraints or change existing ones.
Drawbacks of file systems (cont.)
• Atomicity of updates
Failures may leave database in an inconsistent state with
partial updates carried out.
E.g. transfer of funds from one account to another should
either complete or not happen at all.
• Concurrent access by multiple users
Concurrent accessed needed for performance.
Uncontrolled concurrent accesses can lead to inconsistencies
E.g. two people reading a balance and updating it at the same
time.
• Security problems
Database systems offer solutions to all the above
problems
Drawbacks of file systems (cont.)
Advantage of DBMS over file system
•No redundant data: Redundancy removed by data normalization. No data
duplication saves storage and improves access time.
•Data Consistency and Integrity:data normalization takes care of the data
redundancy, data inconsistency also been. taken care of as part of it.
•Data Security: It is easier to apply access constraints in database systems
so that only authorized user is able to access the data.
Each user has a different set of access thus data is secured from the issues
such as identity theft, data leaks and misuse of data.
•Privacy: Limited access means privacy of data.
•Easy access to data – Database systems manages data in such a way so
that the data is easily accessible with fast response times.
•Easy recovery: Since database systems keeps the backup of data, it is
easier to do a full recovery of data in case of a failure.
•Flexible: Database systems are more flexible than file processing systems
Physical level/Internal level : It describes how a
record (e.g., customer) is stored.
Logical level/Conceptual level: It 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.
Levels of Abstraction
Views of Data
External
view: User &
Data
Designer
Conceptual
Schema:
Data
Designer
Physical
Storage:
DBA
An architecture for a database system
Views of Data
Physical level/Internal level : The physical
representation of the database on the computer.
This level describes how the data is stored in the
database.
• It includes :
 Where the data is located
 File structures
 Access methods
 Indexes.
The physical schema is managed by the DBA.
Logical level/Conceptual level: The community view of
the database. This level describes what data is stored
in the database and the relationships among the data.
• What are the entities and Relationships in
organization.
• What information these entities and relationships
should store in database.
• What integrity constraints/business rules it should
have?
• It consists of the schemas we have described with
CREATE TABLE statements.
Views of Data
View level/ External Level: The users view of the
database. This level describes that part of the
database that is relevant to each user.
• Each external schema is a combination of base
tables and views, tailored to the needs of a single
user.
• It is managed by the data designer and the user.
Views of Data
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
Balance of conflicting requirements
Improved data accessibility and responsiveness
Increased productivity
Improved maintenance through data independence
Disadvantages of DBMS
Complexity – provision of the functionality we expect
from DBMS makes it extremely complex.
Size – complexity and breadth of functionality makes DBMS
extremely large piece of software.
Cost of DBMSs – it varies significantly depending on
the environment & functionality provided.
Additional hardware costs – to achieve required
performance, it is necessary to procure large memory.
Performance – DBMS is written to be more general, to
cater for many applications rather than just one.
Higher impact of failure – Centralization of resources
increases the vulnerability of the system. Since all users &
applications rely on DBMS, the failure of one component
can bring operations to a halt.
Components of the DBMS
1. Hardware – DBMS and the applications require hardware to
run.
• It can range from PCto mainframe or network of
computers.
• It depends on the organization’s requirements and the
DBMS used.
2. Software – It comprises of following :
• DBMS software itself
• Application program
• Operating System including network software
3. Data - Most important component from end-user’s point
of view.
• It acts as a bridge between the machine components
and the human component.
• The database contains both operational data and the
metadata.
Components of the DBMS
4. Procedures – It refers to the instructions and rules that
govern the design and use of the database.
• Users of the system require documented procedures
on how to use/run the system.
• It may consists of instructions like
• Log on to the DBMS
• Use a particular DBMS facility or application
program.
• Start and stop DBMS
• Make backup copies of the database
• Handle H/W and S/W failures.
• Change structure of table to improve performance
5. People – i.e USERS
Overall System Structure
indices Statistical data
Data files Data dictionary
disk storage
Database Users
Users are differentiated by the way they expect to interact with the
system.
1. Application programmers: They are the developers who interact
with the database by means of DML queries. These DML queries
are written in the application programs like C, C++, JAVA, Pascal
etc. These queries are converted into object code to communicate
with the database.
For example, writing a C program to generate the report of employees
who are working in particular department will involve a query to
fetch the data from database. It will include a embedded SQL query in
the C Program.
Database Users
2. Sophisticated users : They are database developers, who write SQL
queries to select/insert/delete/update data. They do not use any
application or programs to request the database. They directly
interact with the database by means of query language like SQL.
These users will be scientists, engineers, analysts who thoroughly
study SQL and DBMS to apply the concepts in their requirement. In
short, we can say this category includes designers and developers of
DBMS and SQL.
3. Specialized users: These are also sophisticated users, but they write
special database application programs. They are the developers who
develop the complex programs to the requirement.
Database Users
4. Stand-alone Users - These users will have stand –alone
database for their personal use. These kinds of database will
have readymade database packages which will have menus and
graphical interfaces.
5. Naive users: These are the users who use the existing
application to interact with the database. For example, online
library system, ticket booking systems, ATMs etc which has
existing application and users use them to interact with the
database to fulfill their requests.
Database Administrator
Coordinates all the activities of the database system;
the database administrator has a good understanding
of the enterprise’s information resources and needs:
Database administrator’s duties include:
• Schema definition
• Storage structure and access method definition
• Schema and physical organization modification
• Granting user authority to access the database
• Specifying integrity constraints
• Monitoring performance and responding to changes in
requirements
Instances and Schemas
Similar to types and variables in programming languages
Schema – the logical structure of the database
e.g., the database consists of information about a set of customers and
accounts and the relationship between them)
Analogous to type information of a variable in a program
Physical schema: database design at the physical level
Logical schema: database design at the logical level
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.
Storage Manager/Storage Management:
storage manager components include:
Authorization and integrity manager
•Transaction manager
•File manager
•Buffer manager
•Data structures implemented by storage manager.
•Data files: Stored in the database itself.
•Data dictionary: Stores metadata about the structure of the database.
•Indices: Provide fast access to data items.
Data Models
concepts for describing and manipulating the
An integrated collection of
following in an organization:
• Data
• Data relationships
• Data semantics
• Data constraints
Facilitate interaction among the designer, the applications programmer, and the
end user
A data model can be thought of as comprising 3components:
• Structural Part – consisting of set of rules according to which databases can
be structured.
• Manipulative part – defining the types of operations that are allowed on the
data (includes insertion, retrieval or updating)
• Set of integrity rules – for ensuring that data is accurate.
Instance – the actual content of the database i.e. actual data at a particular
point in time .
• Analogous to the value of a variable.
• The actual data in the database may change very frequently.
Thus many database instances can correspond to the same database
schema.
The schema is sometimes called as intension of the database.
The instance is sometimes called as extension or state of the database.
Schemas and Instances
Three-Schema Architecture
• Defines DBMS schemas at three levels:
• Internal schema at the internal level to describe physical
storage structures and access paths. Typically uses a
physical data model.
• Conceptual schema at the conceptual level to describe the
structure and constraints for the whole database for a
community of users. Uses a conceptual or an
implementation data model.
• External schemas at the external level to describe the
various user views. Usually uses the same data model as the
conceptual level.
The disjointing of data descriptions from the application programs (or user-
interfaces) that uses the data is called data independence.
Data independence is one of the main advantages of DBMS.
The three-schema architecture provides the concept of data independence,
which means that upper-levels are unaffected by changes to lower-levels.
The interfaces between the various levels and components should be well
defined so that changes in some parts do not seriously influence others.
There are two kinds of data independence.
• Physical Data Independence
• Logical Data Independence
Data Independence
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.
Logical Data Independence – the ability to modify the conceptual
schema without changing the application program
• Usually done when logical structure of database is altered.
• Logical data independence is harder to achieve as the application
programs are usually heavily dependent on the logical structure of
the data. An analogy is made to abstract data types in
programming languages.
Types of Data Independence
Specification notation for defining the database
schema
◦ E.g.
create table account (
account-number char(10),
balance integer)
DDL compiler generates a set of tables stored in
a data dictionary
Data dictionary contains metadata (i.e., data
about data)
◦ database schema
◦ Data storage and definition language
language in which the storage structure and access
methods used by the database system are specified
Usually an extension of the data definition language
Data Definition Language (DDL)
SQL
SQL: widely used non-procedural language
E.g. find the name of the customer with customer-id 192-83-7465
select customer.customer-name
from customer
where customer.customer-id = ‘192-83-7465’
E.g. find the balances of all accounts held by the customer with customer-id 192-83-
7465
select account.balance
from depositor, account
where depositor.customer-id = ‘192-83-7465’ and
depositor.account-number = account.account-number
Application programs generally access databases through one of
Language extensions to allow embedded SQL
Application program interface (e.g. ODBC/JDBC) which allow SQL queries to be sent to
a database
1 von 30

Recomendados

Database systems von
Database systemsDatabase systems
Database systemsNazmulHossen5
283 views13 Folien
Distributed Database Management System von
Distributed Database Management SystemDistributed Database Management System
Distributed Database Management SystemHardik Patil
33.7K views87 Folien
Database user and administrator.pptx von
Database user and administrator.pptxDatabase user and administrator.pptx
Database user and administrator.pptxAnusha sivakumar
156 views10 Folien
Sql server difference faqs- 4 von
Sql server difference faqs- 4Sql server difference faqs- 4
Sql server difference faqs- 4Umar Ali
1.5K views2 Folien
Structured Query Language (SQL) von
Structured Query Language (SQL)Structured Query Language (SQL)
Structured Query Language (SQL)Syed Hassan Ali
2.1K views11 Folien
ADO.NET von
ADO.NETADO.NET
ADO.NETWani Zahoor
1.2K views20 Folien

Más contenido relacionado

Was ist angesagt?

Database backup and recovery von
Database backup and recoveryDatabase backup and recovery
Database backup and recoveryAnne Lee
7.1K views8 Folien
Unit 01 dbms von
Unit 01 dbmsUnit 01 dbms
Unit 01 dbmsanuragmbst
2.4K views34 Folien
Database Programming von
Database ProgrammingDatabase Programming
Database ProgrammingHenry Osborne
2.9K views28 Folien
Database design von
Database designDatabase design
Database designDhani Ahmad
5.1K views50 Folien
Introduction to Dimesional Modelling von
Introduction to Dimesional ModellingIntroduction to Dimesional Modelling
Introduction to Dimesional ModellingAshish Chandwani
1.3K views21 Folien
Information Storage and Management notes ssmeena von
Information Storage and Management notes ssmeena Information Storage and Management notes ssmeena
Information Storage and Management notes ssmeena ssmeena7
8K views10 Folien

Was ist angesagt?(20)

Database backup and recovery von Anne Lee
Database backup and recoveryDatabase backup and recovery
Database backup and recovery
Anne Lee7.1K views
Unit 01 dbms von anuragmbst
Unit 01 dbmsUnit 01 dbms
Unit 01 dbms
anuragmbst2.4K views
Database design von Dhani Ahmad
Database designDatabase design
Database design
Dhani Ahmad5.1K views
Introduction to Dimesional Modelling von Ashish Chandwani
Introduction to Dimesional ModellingIntroduction to Dimesional Modelling
Introduction to Dimesional Modelling
Ashish Chandwani1.3K views
Information Storage and Management notes ssmeena von ssmeena7
Information Storage and Management notes ssmeena Information Storage and Management notes ssmeena
Information Storage and Management notes ssmeena
ssmeena78K views
Distributed design alternatives von Pooja Dixit
Distributed design alternativesDistributed design alternatives
Distributed design alternatives
Pooja Dixit4.2K views
Object Oriented Database Management System von Ajay Jha
Object Oriented Database Management SystemObject Oriented Database Management System
Object Oriented Database Management System
Ajay Jha11.5K views
Database systems - Chapter 1 von shahab3
Database systems - Chapter 1Database systems - Chapter 1
Database systems - Chapter 1
shahab32.6K views
Database management systems von Joel Briza
Database management systemsDatabase management systems
Database management systems
Joel Briza2K views
System development approaches von Jaipal Dhobale
System development approachesSystem development approaches
System development approaches
Jaipal Dhobale10.3K views

Similar a Unit1 dbms

Unit 1: Introduction to DBMS Unit 1 Complete von
Unit 1: Introduction to DBMS Unit 1 CompleteUnit 1: Introduction to DBMS Unit 1 Complete
Unit 1: Introduction to DBMS Unit 1 CompleteRaj vardhan
8.3K views90 Folien
Chapter 1. Itroduction To DBMS -.pptx von
Chapter 1. Itroduction To DBMS -.pptxChapter 1. Itroduction To DBMS -.pptx
Chapter 1. Itroduction To DBMS -.pptxsantosh96234
5 views11 Folien
Intoduction- Database Management System von
Intoduction- Database Management SystemIntoduction- Database Management System
Intoduction- Database Management SystemDr. Jasmine Beulah Gnanadurai
180 views49 Folien
Database & Database Users von
Database & Database UsersDatabase & Database Users
Database & Database UsersM.Zalmai Rahmani
1.6K views38 Folien
Beginning Of DBMS (data base) von
Beginning Of DBMS (data base)Beginning Of DBMS (data base)
Beginning Of DBMS (data base)Surya Swaroop
99 views39 Folien

Similar a Unit1 dbms(20)

Unit 1: Introduction to DBMS Unit 1 Complete von Raj vardhan
Unit 1: Introduction to DBMS Unit 1 CompleteUnit 1: Introduction to DBMS Unit 1 Complete
Unit 1: Introduction to DBMS Unit 1 Complete
Raj vardhan8.3K views
Chapter 1. Itroduction To DBMS -.pptx von santosh96234
Chapter 1. Itroduction To DBMS -.pptxChapter 1. Itroduction To DBMS -.pptx
Chapter 1. Itroduction To DBMS -.pptx
santosh962345 views
Beginning Of DBMS (data base) von Surya Swaroop
Beginning Of DBMS (data base)Beginning Of DBMS (data base)
Beginning Of DBMS (data base)
Surya Swaroop99 views
DBMS-INTRODUCTION.pptx von DivyaKS12
DBMS-INTRODUCTION.pptxDBMS-INTRODUCTION.pptx
DBMS-INTRODUCTION.pptx
DivyaKS12189 views
Introduction & history of dbms von sethu pm
Introduction & history of dbmsIntroduction & history of dbms
Introduction & history of dbms
sethu pm18.9K views
Unit 2 rdbms study_material von gayaramesh
Unit 2  rdbms study_materialUnit 2  rdbms study_material
Unit 2 rdbms study_material
gayaramesh224 views
Introduction to DBMS.pptx von Sreenivas R
Introduction to DBMS.pptxIntroduction to DBMS.pptx
Introduction to DBMS.pptx
Sreenivas R2 views
Dbms models von devgocool
Dbms modelsDbms models
Dbms models
devgocool66.1K views
Chap1-Introduction to database systems.ppt von LisaMalar
Chap1-Introduction to database systems.pptChap1-Introduction to database systems.ppt
Chap1-Introduction to database systems.ppt
LisaMalar29 views

Último

Object Oriented Programming with JAVA von
Object Oriented Programming with JAVAObject Oriented Programming with JAVA
Object Oriented Programming with JAVADemian Antony D'Mello
140 views28 Folien
What is Whirling Hygrometer.pdf von
What is Whirling Hygrometer.pdfWhat is Whirling Hygrometer.pdf
What is Whirling Hygrometer.pdfIIT KHARAGPUR
12 views3 Folien
Advances in micro milling: From tool fabrication to process outcomes von
Advances in micro milling: From tool fabrication to process outcomesAdvances in micro milling: From tool fabrication to process outcomes
Advances in micro milling: From tool fabrication to process outcomesShivendra Nandan
7 views18 Folien
DevOps-ITverse-2023-IIT-DU.pptx von
DevOps-ITverse-2023-IIT-DU.pptxDevOps-ITverse-2023-IIT-DU.pptx
DevOps-ITverse-2023-IIT-DU.pptxAnowar Hossain
9 views45 Folien
Pull down shoulder press final report docx (1).pdf von
Pull down shoulder press final report docx (1).pdfPull down shoulder press final report docx (1).pdf
Pull down shoulder press final report docx (1).pdfComsat Universal Islamabad Wah Campus
13 views25 Folien
Control Systems Feedback.pdf von
Control Systems Feedback.pdfControl Systems Feedback.pdf
Control Systems Feedback.pdfLGGaming5
6 views39 Folien

Último(20)

Advances in micro milling: From tool fabrication to process outcomes von Shivendra Nandan
Advances in micro milling: From tool fabrication to process outcomesAdvances in micro milling: From tool fabrication to process outcomes
Advances in micro milling: From tool fabrication to process outcomes
Control Systems Feedback.pdf von LGGaming5
Control Systems Feedback.pdfControl Systems Feedback.pdf
Control Systems Feedback.pdf
LGGaming56 views
Investigation of Physicochemical Changes of Soft Clay around Deep Geopolymer ... von AltinKaradagli
Investigation of Physicochemical Changes of Soft Clay around Deep Geopolymer ...Investigation of Physicochemical Changes of Soft Clay around Deep Geopolymer ...
Investigation of Physicochemical Changes of Soft Clay around Deep Geopolymer ...
AltinKaradagli9 views
Design of machine elements-UNIT 3.pptx von gopinathcreddy
Design of machine elements-UNIT 3.pptxDesign of machine elements-UNIT 3.pptx
Design of machine elements-UNIT 3.pptx
gopinathcreddy32 views
DevOps to DevSecOps: Enhancing Software Security Throughout The Development L... von Anowar Hossain
DevOps to DevSecOps: Enhancing Software Security Throughout The Development L...DevOps to DevSecOps: Enhancing Software Security Throughout The Development L...
DevOps to DevSecOps: Enhancing Software Security Throughout The Development L...
Anowar Hossain13 views
2023Dec ASU Wang NETR Group Research Focus and Facility Overview.pptx von lwang78
2023Dec ASU Wang NETR Group Research Focus and Facility Overview.pptx2023Dec ASU Wang NETR Group Research Focus and Facility Overview.pptx
2023Dec ASU Wang NETR Group Research Focus and Facility Overview.pptx
lwang7853 views
Machine Element II Course outline.pdf von odatadese1
Machine Element II Course outline.pdfMachine Element II Course outline.pdf
Machine Element II Course outline.pdf
odatadese19 views

Unit1 dbms

  • 1. By : Mrs. V. Gowri, AP/CSE Unit 1: Introduction to DBMS
  • 2. Set of programs to access the data DBMS contains information about a particular enterprise DBMS provides an environment that is both convenient and efficient to use. Database Applications: • Banking: all transactions • Airlines: reservations, schedules • Universities: registration, grades • Sales: customers, products, purchases • Manufacturing: production, inventory, orders, supply chain • Human resources: employee records, salaries, tax deductions Databases touch all aspects of our lives Database Management System (DBMS) Collection of interrelated data
  • 3. In the early days, database applications were built on top of file systems. Drawbacks of using file systems to store data: Data redundancy and inconsistency - duplication of information in different files. • Uncontrolled duplication of data is undesirable for following reasons: Duplication costs time and money to enter data more than once. It takes additional storage space thus again increasing associated costs. It can be avoided by sharing data files. It may lead to data inconsistency. Difficulty in accessing data Need to write a new program to carry out each new task. Purpose of Database System
  • 4. • Data isolation — multiple files and formats. • When data is isolated in separate files, it is more difficult to access data and to ensure that data is correct. • Also, the structure of file depends on application programming language. Thus the direct incompatibility of such files makes it difficult to process jointly. • Integrity problems Integrity constraints (e.g. account balance > 0) become part of program code Hard to add new constraints or change existing ones. Drawbacks of file systems (cont.)
  • 5. • Atomicity of updates Failures may leave database in an inconsistent state with partial updates carried out. E.g. transfer of funds from one account to another should either complete or not happen at all. • Concurrent access by multiple users Concurrent accessed needed for performance. Uncontrolled concurrent accesses can lead to inconsistencies E.g. two people reading a balance and updating it at the same time. • Security problems Database systems offer solutions to all the above problems Drawbacks of file systems (cont.)
  • 6. Advantage of DBMS over file system •No redundant data: Redundancy removed by data normalization. No data duplication saves storage and improves access time. •Data Consistency and Integrity:data normalization takes care of the data redundancy, data inconsistency also been. taken care of as part of it. •Data Security: It is easier to apply access constraints in database systems so that only authorized user is able to access the data. Each user has a different set of access thus data is secured from the issues such as identity theft, data leaks and misuse of data. •Privacy: Limited access means privacy of data.
  • 7. •Easy access to data – Database systems manages data in such a way so that the data is easily accessible with fast response times. •Easy recovery: Since database systems keeps the backup of data, it is easier to do a full recovery of data in case of a failure. •Flexible: Database systems are more flexible than file processing systems
  • 8. Physical level/Internal level : It describes how a record (e.g., customer) is stored. Logical level/Conceptual level: It 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. Levels of Abstraction
  • 9. Views of Data External view: User & Data Designer Conceptual Schema: Data Designer Physical Storage: DBA An architecture for a database system
  • 10. Views of Data Physical level/Internal level : The physical representation of the database on the computer. This level describes how the data is stored in the database. • It includes :  Where the data is located  File structures  Access methods  Indexes. The physical schema is managed by the DBA.
  • 11. Logical level/Conceptual level: The community view of the database. This level describes what data is stored in the database and the relationships among the data. • What are the entities and Relationships in organization. • What information these entities and relationships should store in database. • What integrity constraints/business rules it should have? • It consists of the schemas we have described with CREATE TABLE statements. Views of Data
  • 12. View level/ External Level: The users view of the database. This level describes that part of the database that is relevant to each user. • Each external schema is a combination of base tables and views, tailored to the needs of a single user. • It is managed by the data designer and the user. Views of Data
  • 13. 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 Balance of conflicting requirements Improved data accessibility and responsiveness Increased productivity Improved maintenance through data independence
  • 14. Disadvantages of DBMS Complexity – provision of the functionality we expect from DBMS makes it extremely complex. Size – complexity and breadth of functionality makes DBMS extremely large piece of software. Cost of DBMSs – it varies significantly depending on the environment & functionality provided. Additional hardware costs – to achieve required performance, it is necessary to procure large memory. Performance – DBMS is written to be more general, to cater for many applications rather than just one. Higher impact of failure – Centralization of resources increases the vulnerability of the system. Since all users & applications rely on DBMS, the failure of one component can bring operations to a halt.
  • 15. Components of the DBMS 1. Hardware – DBMS and the applications require hardware to run. • It can range from PCto mainframe or network of computers. • It depends on the organization’s requirements and the DBMS used. 2. Software – It comprises of following : • DBMS software itself • Application program • Operating System including network software 3. Data - Most important component from end-user’s point of view. • It acts as a bridge between the machine components and the human component. • The database contains both operational data and the metadata.
  • 16. Components of the DBMS 4. Procedures – It refers to the instructions and rules that govern the design and use of the database. • Users of the system require documented procedures on how to use/run the system. • It may consists of instructions like • Log on to the DBMS • Use a particular DBMS facility or application program. • Start and stop DBMS • Make backup copies of the database • Handle H/W and S/W failures. • Change structure of table to improve performance 5. People – i.e USERS
  • 17. Overall System Structure indices Statistical data Data files Data dictionary disk storage
  • 18. Database Users Users are differentiated by the way they expect to interact with the system. 1. Application programmers: They are the developers who interact with the database by means of DML queries. These DML queries are written in the application programs like C, C++, JAVA, Pascal etc. These queries are converted into object code to communicate with the database. For example, writing a C program to generate the report of employees who are working in particular department will involve a query to fetch the data from database. It will include a embedded SQL query in the C Program.
  • 19. Database Users 2. Sophisticated users : They are database developers, who write SQL queries to select/insert/delete/update data. They do not use any application or programs to request the database. They directly interact with the database by means of query language like SQL. These users will be scientists, engineers, analysts who thoroughly study SQL and DBMS to apply the concepts in their requirement. In short, we can say this category includes designers and developers of DBMS and SQL. 3. Specialized users: These are also sophisticated users, but they write special database application programs. They are the developers who develop the complex programs to the requirement.
  • 20. Database Users 4. Stand-alone Users - These users will have stand –alone database for their personal use. These kinds of database will have readymade database packages which will have menus and graphical interfaces. 5. Naive users: These are the users who use the existing application to interact with the database. For example, online library system, ticket booking systems, ATMs etc which has existing application and users use them to interact with the database to fulfill their requests.
  • 21. Database Administrator Coordinates all the activities of the database system; the database administrator has a good understanding of the enterprise’s information resources and needs: Database administrator’s duties include: • Schema definition • Storage structure and access method definition • Schema and physical organization modification • Granting user authority to access the database • Specifying integrity constraints • Monitoring performance and responding to changes in requirements
  • 22. Instances and Schemas Similar to types and variables in programming languages Schema – the logical structure of the database e.g., the database consists of information about a set of customers and accounts and the relationship between them) Analogous to type information of a variable in a program Physical schema: database design at the physical level Logical schema: database design at the logical level 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.
  • 23. Storage Manager/Storage Management: storage manager components include: Authorization and integrity manager •Transaction manager •File manager •Buffer manager •Data structures implemented by storage manager. •Data files: Stored in the database itself. •Data dictionary: Stores metadata about the structure of the database. •Indices: Provide fast access to data items.
  • 24. Data Models concepts for describing and manipulating the An integrated collection of following in an organization: • Data • Data relationships • Data semantics • Data constraints Facilitate interaction among the designer, the applications programmer, and the end user A data model can be thought of as comprising 3components: • Structural Part – consisting of set of rules according to which databases can be structured. • Manipulative part – defining the types of operations that are allowed on the data (includes insertion, retrieval or updating) • Set of integrity rules – for ensuring that data is accurate.
  • 25. Instance – the actual content of the database i.e. actual data at a particular point in time . • Analogous to the value of a variable. • The actual data in the database may change very frequently. Thus many database instances can correspond to the same database schema. The schema is sometimes called as intension of the database. The instance is sometimes called as extension or state of the database. Schemas and Instances
  • 26. Three-Schema Architecture • Defines DBMS schemas at three levels: • Internal schema at the internal level to describe physical storage structures and access paths. Typically uses a physical data model. • Conceptual schema at the conceptual level to describe the structure and constraints for the whole database for a community of users. Uses a conceptual or an implementation data model. • External schemas at the external level to describe the various user views. Usually uses the same data model as the conceptual level.
  • 27. The disjointing of data descriptions from the application programs (or user- interfaces) that uses the data is called data independence. Data independence is one of the main advantages of DBMS. The three-schema architecture provides the concept of data independence, which means that upper-levels are unaffected by changes to lower-levels. The interfaces between the various levels and components should be well defined so that changes in some parts do not seriously influence others. There are two kinds of data independence. • Physical Data Independence • Logical Data Independence Data Independence
  • 28. 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. Logical Data Independence – the ability to modify the conceptual schema without changing the application program • Usually done when logical structure of database is altered. • Logical data independence is harder to achieve as the application programs are usually heavily dependent on the logical structure of the data. An analogy is made to abstract data types in programming languages. Types of Data Independence
  • 29. Specification notation for defining the database schema ◦ E.g. create table account ( account-number char(10), balance integer) DDL compiler generates a set of tables stored in a data dictionary Data dictionary contains metadata (i.e., data about data) ◦ database schema ◦ Data storage and definition language language in which the storage structure and access methods used by the database system are specified Usually an extension of the data definition language Data Definition Language (DDL)
  • 30. SQL SQL: widely used non-procedural language E.g. find the name of the customer with customer-id 192-83-7465 select customer.customer-name from customer where customer.customer-id = ‘192-83-7465’ E.g. find the balances of all accounts held by the customer with customer-id 192-83- 7465 select account.balance from depositor, account where depositor.customer-id = ‘192-83-7465’ and depositor.account-number = account.account-number Application programs generally access databases through one of Language extensions to allow embedded SQL Application program interface (e.g. ODBC/JDBC) which allow SQL queries to be sent to a database