Chapter 02
Chapter 02
Database Environment
2
Lecture2Objectives
Purpose/importanceofconceptualmodeling.
TypicalfunctionsandservicesaDBMSshould
provide.
SoftwarecomponentsofaDBMS.
Meaningofclientserverarchitectureand
advantagesofthistypeofarchitecturefora
DBMS.
Functionandimportanceofthesystemcatalog.
3
ObjectivesofThreeLevelArchitecture
Allusersshouldbeabletoaccesssamedata.
Auser'sviewisimmunetochangesmadein
otherviews.
Usersshouldnotneedtoknowphysical
databasestoragedetails.
4
ObjectivesofThreeLevelArchitecture
DBAshouldbeabletochangedatabasestorage
structureswithoutaffectingtheusers'views.
Internalstructureofdatabaseshouldbe
unaffectedbychangestophysicalaspectsof
storage.
DBAshouldbeabletochangeconceptual
structureofdatabasewithoutaffectingallusers.
5
ANSISPARCThreelevelArchitecture
6
ANSISPARCThreelevelArchitecture
ExternalLevel
Users'viewofthedatabase.
Describesthatpartofdatabasethatis
relevanttoaparticularuser.
ConceptualLevel
Communityviewofthedatabase.
Describeswhatdataisstoredindatabaseand
relationshipsamongthedata.
7
ANSISPARCThreelevelArchitecture
InternalLevel
Physicalrepresentationofthedatabaseon
thecomputer.
Describeshowthedataisstoredinthe
database.
8
DifferencesbetweenThreeLevelsofANSI
SPARCArchitecture
9
DataIndependence
LogicalDataIndependence
Referstoimmunityofexternalschemasto
changesinconceptualschema.
Conceptualschemachanges(e.g.
addition/removalofentities).
Shouldnotrequirechangestoexternal
schemaorrewritesofapplicationprograms.
10
DataIndependence
PhysicalDataIndependence
Referstoimmunityofconceptualschemato
changesintheinternalschema.
Internalschemachanges(e.g.usingdifferent
fileorganizations,storagestructures/devices).
Shouldnotrequirechangetoconceptualor
externalschemas.
11
DataIndependenceandtheANSISPARC
ThreelevelArchitecture
12
DatabaseLanguages
DataDefinitionLanguage(DDL)
AllowstheDBAorusertodescribeand
nameentities,attributes,andrelationships
requiredfortheapplication
plusanyassociatedintegrityandsecurity
constraints.
13
DatabaseLanguages
DataManipulationLanguage(DML)
Providesbasicdatamanipulationoperations
ondataheldinthedatabase.
ProceduralDML
allowsusertotellsystemexactlyhowto
manipulatedata.
NonProceduralDML
allowsusertostatewhatdataisneeded
ratherthanhowitistoberetrieved.
14
DatabaseLanguages
FourthGenerationLanguage(4GL)
QueryLanguages
FormsGenerators
ReportGenerators
GraphicsGenerators
ApplicationGenerators
15
DataModel
Integratedcollectionofconceptsfordescribing
data,relationshipsbetweendata,and
constraintsonthedatainanorganization.
DataModelcomprises:
Astructuralpart
Amanipulativepart
Possiblyasetofintegrityrules
16
DataModel
Purpose
Torepresentdatainanunderstandableway.
Categoriesofdatamodelsinclude:
Objectbased
Recordbased
Physical
17
DataModels
ObjectbasedDataModels
EntityRelationship
Semantic
Functional
ObjectOriented
RecordbasedDataModels
RelationalDataModel
NetworkDataModel
HierarchicalDataModel
PhysicalDataModels
18
Conceptualmodeling
Conceptualschemaisthecoreofasystem
supportingalluserviews.
Shouldbecompleteandaccuraterepresentation
ofanorganization'sdatarequirements.
Conceptualmodelingisprocessofdevelopinga
modelofinformationusethatisindependentof
implementationdetails.
Resultisaconceptualdatamodel.
19
FunctionsofaDBMS
DataStorage,Retrieval,andUpdate.
AUserAccessibleCatalog.
TransactionSupport.
ConcurrencyControlServices.
RecoveryServices.
20
FunctionsofaDBMS
AuthorizationServices.
SupportforDataCommunication.
IntegrityServices.
ServicestoPromoteDataIndependence.
UtilityServices.
21
ComponentsofaDBMS
22
ComponentsofDatabaseManager(DM)
23
MultiUserDBMSArchitectures
Teleprocessing
Fileserver
Clientserver
24
Clientserver
ServerholdsthedatabaseandtheDBMS.
Clientmanagesuserinterfaceandruns
applications.
Advantagesinclude:
wideraccesstoexistingdatabases
increasedperformance
possiblereductioninhardwarecosts
reductionincommunicationcosts
increasedconsistency.
25
ClientserverArchitecture
26
SystemCatalog
Repositoryofinformation(metadata)
describingthedatainthedatabase.
Typicallystores:
Namesofauthorizedusers.
Namesofdataitemsinthedatabase.
Constraintsoneachdataitem.
Dataitemsaccessiblebyauserandthetypeofaccess.
UsedbymodulessuchasAuthorization
ControlandIntegrityChecker.
27