ARCHITECTURE OF DBMS (1).ppt

461 views 20 slides Aug 23, 2022
Slide 1
Slide 1 of 20
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14
Slide 15
15
Slide 16
16
Slide 17
17
Slide 18
18
Slide 19
19
Slide 20
20

About This Presentation

Architecture


Slide Content

Architecture ofDBMS
1

Introduction : DBMS Architecture
•DBMSisacollectionofprogramsthatenabletheuserstocreateand
maintainthedatabase.
•PurposeofDBMSistoprovidetheuserwiththeabstractviewof
databasei.e.systemdoesnotprovideallthedetailsofthedata,ratherit
hidesthedetailshowdataisstored&maintained.
•Inordertousethesystem,datamustberetrievedefficiently.
•Thisleadstothedesignofcomplexdatastructuresinthedatabase.
2

DBMSArchitecture
3

Three levels of thearchitecture
External–individualuserview
Conceptual–communityuserview
Internal–physicalorstorageview
Thethreeleveldatabasearchitectureallowsaclear
separationoftheinformationmeaning(conceptual
view)fromtheexternaldatarepresentationandfrom
thephysicaldatastructurelayout.Adatabasesystem
thatisabletoseparatethethreedifferentviewsofdata
islikelytobeflexibleandadaptable.Thisflexibilityand
adaptabilityisdataindependence

External View/Level/Schema/ User View/Global View
•HighestorToplevelofdataabstraction(Noknowledge
ofDBMSS/WandH/Worphysicalstorage).
•Thislevelisconcernedwiththeuser.
•Eachexternalschemadescribesthepartofthe
databasethataparticularuserisinterestedinand
hidestherestofthedatabasefromuser.
•Therecanbennumberofexternalviewsfordatabase
wherenisthenumberofusers.
•Forexample,aaccountsdepartmentmayonlybe
interestedinthestudentfeedetails.Itwouldnotbe
expectedtohaveanyinterestinthepersonal
informationaboutstudents.
5

ConceptualView
•Thislevelisinbetweentheuserlevelandphysicalstorage
view.
•Thereisonlyoneconceptualviewforsingledatabase.
•Ithidesthedetailsofphysicalstoragestructuresand
concentratesondescribingentities,datatypes,relationships,
useroperations,andconstraints.
6

InternalView/PhysicalView
•Itisthelowestlevelofdataabstraction.(ithasthe
knowledgeabouts/wandh/w)
•Atthislevel,itkeepstheinformationabouttheactual
representationoftheentiredatabasei.e.theactualstorage
ofthedataonthediskintheformofrecordsorblocks.
•Itisclosetothephysicalstoragemethod.
•Theinternalviewistheviewthattellsuswhatdataisstored
inthedatabaseandhow.Atleastthefollowingaspectsare
consideredatthislevel:Storageallocation,Accesspathsetc.
•Theinternalviewdoesnotdealwiththephysicaldevices
directly.Insteaditviewsaphysicaldeviceasacollectionof
physicalpagesandallocatesspaceintermsoflogicalpages.
7

TYPESOFDATAINDEPENDENCE
1.LOGICALDATAINDEPENDENCE
2.PHYSICALDATAINDEPENDENCE
8

LOGICALDATAINDEPENDENCE
•Whenever,thereisachangeormodificationatthe
conceptuallevelwithoutaffectingtheuserlevelor
externallevel,itisknownaslogicaldataindependence.
•E.g.Thenamefieldinconceptualviewisstoredasfirst
name,middlenameandlastnamewhereasinexternal
view,itremainstobeasasinglenamefield.
9

PHYSICALDATAINDEPENDENCE
•Whenever,thechangesaremadeattheinternallevel
withoutaffectingtheabovelayers,itisknownasphysical
dataindependence.
•E.g.Thelocationofthedatabase,ifchangedfromCdrive
toDdrivewillnotaffecttheconceptualvieworexternal
viewasthecommandsareindependentofthelocationof
thedatabase.
10

Difference between Logical Data Independence & Physical Data
Independence
Application program need not be changed if
new fields are added or deleted from the
database.
Logical Data Independence Physical Data Independence
It is concerned with the structure of the data orIt is concerned with storage of
the data.
changing the data definition.
It is very difficult as the retrieving of data areIt is easy to retrieve.
heavily dependent on logical structure of data.
Physical database is concerned with the
change of the storage device.
It is concerned with the conceptualschema. It is concerned with the internalschema.
11

Database Languages and Interfaces
•DDL
•DML
•DCL
•TCL
Adatabasemanagementsystem(DBMS)interfaceisauserinterfacewhich
allowsfortheabilitytoinputqueriestoadatabasewithoutusingthequery
languageitself.
1.Menu-BasedInterfacesforWebClientsorBrowsing
Theseinterfacespresenttheuserwithlistsofoptions(calledmenus)that
leadtheuserthroughtheformationofarequest.Basicadvantageofusing
menusisthattheyremovesthetensionofrememberingspecific
commandsandsyntaxofanyquerylanguage,ratherthanqueryis
basicallycomposedstepbystepbycollectingorpickingoptionsfroma
menuthatisbasicallyshownbythesystem.Pull-downmenusareavery
populartechniqueinWebbasedinterfaces.

2. Forms-Based Interfaces
1.Aforms-basedinterfacedisplaysaformtoeachuser.Userscanfillout
alloftheformentriestoinsertanewdata,ortheycanfilloutonly
certainentries,inwhichcasetheDBMSwillredeemsametypeofdata
forotherremainingentries.
2.Thistypeofformsareusuallydesignedorcreatedandprogrammed
fortheusersthathavenoexpertiseinoperatingsystem.ManyDBMSs
haveformsspecificationlanguageswhicharespeciallanguagesthat
help specify such forms.
3.Example:SQL*Formsisaform-basedlanguagethatspecifiesqueries
usingaformdesignedinconjunctionwiththerelationaldatabase
schema

3. Graphical User Interface
AGUItypicallydisplaysaschematotheuserindiagrammaticform.
Theuserthencanspecifyaquerybymanipulatingthediagram.In
manycases,GUI’sutilizebothmenusandforms.MostGUIsusea
pointingdevicesuchasmouse,topickcertainpartofthedisplayed
schemadiagram.
4.InterfacesforDBA
Mostdatabasesystemcontainsprivilegedcommandsthatcanbe
usedonlybytheDBA’sstaff.Theseincludecommandsforcreating
accounts,settingsystemparameters,grantingaccountauthorization,
changingaschema,reorganizingthestoragestructuresofa
databases

•Data Definition Language (DDL) statements are used to define
the database structure or schema.
Commands:
1)CREATE -to create objects in the database
2)ALTER -alters the structure of the database
3)DROP -delete objects from the database
4)TRUNCATE -remove all records from a table, including all
spaces allocated for the records are removed
5)RENAME -rename an object

•DataManipulationLanguage(DML)statementsareusedfor
managingdatawithinschemaobjects.
Commands:
1)SELECT -retrieve data from the a database
2)INSERT -insert data into a table
3)UPDATE -updates existing data within a table
4)DELETE -deletes all records from a table, the space for the
records remain
5)MERGE -UPSERT operation (insert or update)

•Data Control Language (DCL) statements.
Commands:
1)GRANT -gives user's access privileges to database
2)REVOKE -withdraw access privileges given with the
GRANT command

•TransactionControl(TCL)statementsareusedtomanagethe
changesmadebyDMLstatements.Itallowsstatementstobe
groupedtogetherintologicaltransactions.
Commands:
1)COMMIT -save work done
2)SAVEPOINT -identify a point in a transaction to which you can later
roll back
3)ROLLBACK -restore database to original since the last COMMIT

Classification of Database Management Systems
Datamodel
•Relational
•Object
•Hierarchicalandnetwork(legacy)
Numberofusers
•Single-user
•Multiuser
Number of sites
•Centralized
•Distributed
•Homogeneous
•Heterogeneous
Cost
•Open source
•Different types of licensing

Types of access path options
General or special-purpose
Note:DBMSclassificationcriteria:
Datamodel,numberofusers,numberofsites,accesspathsandcost
Tags