Sunteți pe pagina 1din 6

%DVHV GH GRQQpHV DYDQFpHV



%DVHV GH GRQQpHV DYDQFpHV


7UDGXFWLRQ VFKpPD FRQFHSWXHO VFKpPD UHODWLRQQHO

&RQFHSWLRQ GXQ VFKpPD UHODWLRQQHO

Phyvrqr qtyr qrhqpv 9vhthrqrpyhrTpuphryhvry

Le schma relationnel obtenu doit prciser clairement: le domaine de tous les attributs les cls primaires les cls trangres le caractre obligatoire ou non des attributs (NULL), le caractre unique (cl secondaire) ou non des attributs, description de toutes les contraintes statiques du diagramme de classes non prises en compte par le schma relationnel (par exemple en algbre relationnelle), les autres contraintes dintgrit

&DV GHV DVVRFLDWLRQV 


A

Implantation conseille

a1{identifiant} a2[0..1]

A(a1, a2) B(b1, b2 iyvthvr) C(@a1 vr, @b1 vr)


Autre implantation (rclamant des valeurs nulles)
B

0..1
^ C

0..1
b1 {identifiant} b2

A(a1, a2, @b1 vr) B(b1, b2 iyvthvr)


Le dport de la cl se fera dans la table qui contiendra le moins de tuple (ici on suppose que cest A).

3KLOLSSH 3LFRXHW (167 %UHWDJQH

%DVHV GH GRQQpHV DYDQFpHV



&DV GHV DVVRFLDWLRQV 


A
a1{identifiant} a2[0..1]

<C

0..1

B
b1 {identifiant} b2

Implantation conseille

A(a1, a2) B(b1, b2 REOLJDWRLUH,@a1 XQLTXH REOLJDWRLUH)

&DV GHV DVVRFLDWLRQV 


A
a1{identifiant} a2[0..1]

<C

B
b1 {identifiant} b2

Implantation conseille AB(a1, a2, b1 vriyvthvr, b2 iyvthvr) Autres implantations A(a1, a2, @b1 vriyvthvr) B(b1, b2 iyvthvr) OU A(a1, a2) B(b1, b2 iyvthvr@a1 vriyvthvr)

&DV GHV DVVRFLDWLRQV 1


A
a1{identifiant} a2[0..1]

0..1

<C

0..*

B
b1 {identifiant} b2

Implantation conseille (rclame des valeurs nulles)

A(a1, a2) B(b1, b2 iyvthvr@a1)


Autre implantation (sans valeur nulle)

A(a1, a2) B(b1, b2 iyvthvr) C(@a1 iyvthvr, @b1)

3KLOLSSH 3LFRXHW (167 %UHWDJQH

%DVHV GH GRQQpHV DYDQFpHV



&DV GHV DVVRFLDWLRQV 1


A
a1{identifiant} a2[0..1]

<C

0..*

B
b1 {identifiant} b2

Implantation conseille

A(a1, a2) B(b1, b2 iyvthvr@a1 iyvthvr)


Autre implantation

A(a1, a2) B(b1, b2 iyvthvr) C(@a1 iyvthvr, @b1)

&DV GHV DVVRFLDWLRQV 1


A
a1{identifiant} a2[0..1]

<C

1..*

B
b1 {identifiant} b2

Implantation conseille

A(a1, a2) B(b1, b2 iyvthvr@a1 iyvthvr)


Autre implantation (sans valeur nulle)

$[D1] %[D1]

A(a1, a2) B(b1, b2 iyvthvr) C(@a1 iyvthvr, @b1)


$[ D1] &[ D1] %[E1] &[E1]

&DV GHV DVVRFLDWLRQV 1


A
a1{identifiant} a2[0..1]

0..1

<C

1..*

B
b1 {identifiant} b2

Implantation conseille

A(a1, a2) B(b1, b2 iyvthvr@a1)


Autre implantation (sans valeur nulle)

$[D1] %[D1]

A(a1, a2) B(b1, b2 iyvthvr) C(@a1 iyvthvr, @b1)


$[ D1] &[ D1]

3KLOLSSH 3LFRXHW (167 %UHWDJQH

%DVHV GH GRQQpHV DYDQFpHV





&DV GHV DVVRFLDWLRQV 11


A
a1{identifiant} a2[0..1]

0..*

<C

0..*

B
b1 {identifiant} b2

c1

Implantation conseille

A(a1, a2) B(b1, b2 iyvthvr) C(@a1, @b1c1 iyvthvr)



&DV GHV DVVRFLDWLRQV 11


A
a1{identifiant} a2[0..1]

1..*

<C

0..*

B
b1 {identifiant} b2

c1

Implantation conseille

A(a1, a2) B(b1, b2 iyvthvr) C(@a1, @b1c1 iyvthvr)


%[E1] & [ E1]



&DV GHV DVVRFLDWLRQV 11


A
a1{identifiant} a2[0..1]

1..*

<C

3..*

B
b1 {identifiant} b2

c1

Implantation conseille

A(a1, a2) B(b1, b2 iyvthvr) C(@a1, @b1c1 iyvthvr)


%[E1] & [ E1]
[ $[ D1], FDUG (& { 1 = [} 3 D )

3KLOLSSH 3LFRXHW (167 %UHWDJQH

%DVHV GH GRQQpHV DYDQFpHV





$VVRFLDWLRQV 5pIOH[LYHV
0..1 role1
A
a1{identifiant} a2[0..1]

0..1 role2

Implantation conseille

A(a1, a2) C(@role1 ref A(a1) XQLTXH, @role2 ref A(a1) XQLTXH)
Autre implantation (rclamant des valeurs nulles)

A(a1, a2, @role1 XQLTXH)



$VVRFLDWLRQV 5pIOH[LYHV
0..1 role1
A
a1{identifiant} a2[0..1]

0..* role2

Implantation conseille

A(a1, a2, @role1)


Autre implantation

A(a1, a2) C(@role1 ref A(a1) REOLJDWRLUH, @role2 ref A(a1))



$VVRFLDWLRQV 5pIOH[LYHV
0..* role1
A
a1{identifiant} a2[0..1]

c1

0..* role2

Implantation conseille

A(a1, a2) C(@role1 ref A(a1), @role2 ref A(a1), c1 REOLJDWRLUH)

3KLOLSSH 3LFRXHW (167 %UHWDJQH

%DVHV GH GRQQpHV DYDQFpHV





/D JpQpUDOLVDWLRQ VLPSOH
$
a1{identifiant} a2[0..1]

B
b1[0..1] b2

C
c1[0..1] c2

Implantation conseille

A(a1, a2, type REOLJDWRLUH) type {B, C} C(@a1, c1, c2 REOLJDWRLUH) *pQpUDOLVDWLRQ  [D1] (%[D1] &[D1]) $
Autre implantation (A sans association)

B(@a1, b1, b2 REOLJDWRLUH)

%[D1] &[ D1] =

B(a1, a2, b1, b2 REOLJDWRLUH) C(a1, a2, c1, c2 REOLJDWRLUH)


Autre implantation

%[D1] &[ D1] =

ABC(a1, a2, b1, b2, c1, c2) E 2 QXOO F 2 = QXOO F1 QXOO F 2 QXOO E1 QXOO E 2 QXOO



3KLOLSSH 3LFRXHW (167 %UHWDJQH

S-ar putea să vă placă și