Chapter 3

28
Chapter 3 1 Chapter 3 Data Modeling Using the Entity-Relationship Model

description

Data modeling

Transcript of Chapter 3

Chapter 3 1Chapter 3Data Modeling Using theEntity-Relationship ModelChapter 3 2Chapter 3 3Entity-Relationship(ER) ModelThe ER model is a high-level onept!al data model"#t has not $een implemented in any ommerial D%M& (')( $!t is a po)er*!l short hand o*ten !sed in data$ase design *or a *irst rendition o* the mini)orld"The ER model )as introd!ed $y +eter Chen in 1,-.( and is no) the most )idely !sed onept!al data model"Chapter 3 /Entity-Relationship(ER) Model(on0t)M!h )or1 has $een done on the ER model( and vario!s e2tensions and enhanements have $een proposed (see Ch" 21 and the te2t Conept!al Data$ase Design $y %atini3Ceri34avathe( %en5amin Commings)"Chapter 3 6De*initions7n entity is an o$5et in the mini)orld"7n attri$!te o* an entity an have a val!e *rom a val!e set (domain)Eah entity $elongs to some one entity type s"t" entities in one entity type have the same attri$!tes (so eah entity type is a set o* similar entities)"Chapter 3 .De*initions (on0t)7 1ey attri$!te o* an entity type is one )hose val!e !ni8!ely identi*ies an entity o* that type"7 om$ination o* attri$!tes may *orm a omposite 1ey"#* there is no applia$le val!e *or an attri$!te that attri$!te is set to a n!ll val!e"Chapter 3 -Entity Type / Entity SetEntity Type (#ntension)9 EM+:;ohn &mith( 66( ?@@@@)e2 = (>oe Doe( /@( 2@@@@)e3 = (>ane Doe( 2-( 3@@@@)...Chapter 3 ?7ttri$!tes7ttri$!tes an $eAomposite 3 simple (atomi)Asingle-val!ed 3 m!ltival!edAstored 3 derivedA1ey 3 non1ey"Chapter 3 ,7ttri$!te E2amples4ame = >ohn Doe%irthdate = May 1@( 1,?,7ge = ,Degree = n!ll&&4 = 123/6.-?,4ame = >ohn Doe%irthdate = May 1@%irthyear = 1,?,7ge = ,Degree = n!ll&&4 = 123/6.-?,4ame = >ane Doe%irthdate = >!ly 11( 1,.@7ge = 3?Degree = %"&"( M"&"&&4 = ,?-.6/321Chapter 3 1@Chapter 3 11EM+:;