1. Trang chủ
  2. » Công Nghệ Thông Tin

bài tập trắc nghiệm cơ sở dữ liệu chương 15 methodology – logical database design for relational model (er – relation mapping) tutorial

4 684 1

Đang tải... (xem toàn văn)

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 4
Dung lượng 64,5 KB

Các công cụ chuyển đổi và chỉnh sửa cho tài liệu này

Nội dung

Chapter 15 Methodology – Logical database design for relational model ER – Relation Mapping Tutorial 1.. Represent the entity and relationship types shown in the ER diagrams below as r

Trang 1

Chapter 15 Methodology – Logical database

design for relational model (ER – Relation Mapping)

Tutorial

1 Represent the entity and relationship types shown in the ER diagrams below as

relations.

Employee

empNo {PK}

name address

Project projectNo {PK}

pName description

WorksOn

Employee

empNo {PK}

name address

Holds

Employment Contract contractNo {PK}

position date salary

Vehicle

regNo {PK}

make model

Check date {PPK}

faults

Has

hours

Supervises

Employee

empNo {PK}

name address

sDate 0 *

0 1

Trang 2

2 The ER diagrams shown below are taken from the example answers for Question 2

and 5 of the Chapter 11 Entity-Relationship Modeling Tutorial However, for the purposes of this tutorial, the attributes associated with entity or relationship types are also included in the diagrams Present a relational schema for each of the ER diagrams shown below

(a)

Dependent

dName {PPK}

dAddress relationship

RelatedTo

0 *

1 1

Company

cName {PK}

cAddress cTelNo cFaxNo

Operates

Department dNo {PK}

dName dLoc

Employs 1 1

Employee

empNo {PK}

name fName lName address

Has

Employment History compOrganName (PPK}

address position sDate fDate

1 *

Trang 3

(b)

OrderDetails

qty status /totalPrice

Requires

Product prodNo {PK} desc price cost numberAllocation reorderQty reorderLevel inStock PartOf

1 *

Customer

custNo {PK} name fName lName address street city postcode telNo creditLimit

Places

Order ordeNo (PK}

status dateDue /totalPrice 1 1

Trang 4

3 Present a relational schema for the ER diagram shown below

Dependent

dName {PPK}

relationship sex birthDate

Project number {PK} name {AK} location

RelatedTo

0 *

1 1

Employee

SSN {PK}

name fName mI lName address sex salary bDate

WorksFor

name {PK}

number locations [1…5] /noOfEmployees

startDate

Manages

Supervises

0 1

0 *

WorksOn

0 *

0 * 1 1

hours

Ngày đăng: 22/10/2014, 10:46

TỪ KHÓA LIÊN QUAN

w