Information Systems - 61

For example:

DEPARTMENTMSK TENK


MONHOC


one many

Belong

MSSV MSK STUDENTS HOT NOW

much

MSMH TENMH LT

TH


much

Register

Many-to-many relationship (nn) is converted into 2 consecutive numbers: 0,n/1,n and 0,n/1,n

16


MSK TENK FACULTY


1,1 1,n

MSSV MSK STUDENTS HOT NOW


1.1


MONHOC


MSMH TENMH LT

TH






Maybe you are interested!


0,n

DK


0,n

MSSV

MSMH



1.1


17

3) Inheritance relationship :

Key of the relationship entity “Parent”is the key

foreign and primary keyof the “Child” relationship entities.

Symbol : Similar to MHYNDL:


Father


KA

...

TTQH CON1

KA

TTTinhDacThu_C1

TTQH CONm

KA


TTTinhDacThu_Cm

18

2. Rules for converting from MHYNDL to MHLDL:

Review some conventions about symbols in

MHYNDL entity-combination form :

A

KA

IA

Represents entity A with the identifying key attribute KA ( KA can be one or a combination of many attributes), the remaining attributes are IA

R

The associative representation R has no attributes.

calculate


R

IR

The associative representation R has the following properties:

IR.19

Step 1: Transfer entity

Rule 1 : Entity will be converted to relational entity , entity attribute will be converted to

attribute of the relational entity . Key recognition

The entity type will be converted to the primary key of the

relational entity


A

KA

IA

A

KA

IA

MHDL


MHLDL is represented as a relational schema:

A( KA , IA)

20

Example 1 : Given a conceptual data model ( SV entity ) , converting it to relational MHLDL according to rule 1 , we get the relational entity SV :



SV

SV

MSSV HOTEN GT NgaySinh

MSSV HOTEN GT NgaySinh

MHDL


SV ( MSSV , HOTEN, GT, NgaySinh)


21

Example 2: There is a conceptual model of the data to be transferred.

MHLDL as follows:


HD

SHD

MHDL

HD

SHD

NOWHD

DIENGIAI QUANTITY


NgayHD DIENGIAI SOTIEN


HD ( SHD , NOWHD , DIENGIAI, SOTIEN)


22


Step 2: Transfer combination

A. SIMPLE COMBINATION


23

Comment


Agree Privacy Policy *