tutorial er 2

2
:: Sem2 2015/2016 ::   ER Diagram 2 Tutorial  TT1964 Database Tutorial ER Diagram   2 Answer all the question based on the following steps:  a) Identify the main entity.  b) Identify the main relationship and specify the cardinality for each relationship. c) Identify / create the attribute and the key attribute (if necessary) d) Draw the complete ER Case Study 1 For a particular business, sales data is very important and it’s represented by the invoice. An invoice written by a sales representative but each sales representative wrote many invoice. A vendor will sell a lot of products, but the product is purchased from one vendor. In each invoice has one or more products and products are available in zero, one or many invoices. Create your own possible attribute for this case study. Case Study 2 Azzalaeachoc Company wants to digitize employee time cards. A timecard should have hours worked and date submitted. Each timecard is associated with exactly one employee and should ha ve a un iq ue id. Ea ch timecard ha s a status either approved, not approved or pen ding. Each employ ee ha s a un iq ue i d , na me and addre ss. Em plo y ee wi ll submi ts a tim ecard every pa y  per i od and st at ed their me th od o f pa yment either direct de po sit o r phy sica l check. Each employee is associated with exactly one manager. Each manager has a unique id and name and he/she will in char g e and appro ve d t imecard for multiple emplo y ees. Y ou need to help Azzaleachoc to design the database for submitting and approving time cards with information given. Case Study 3 A Power Sey is a publishing company that produce books on various area. The books are written  by authors who specialize in one particular area. The company employs editors who, not necessarily being specialists in a particular area, each take sole responsibility for editing one or more publications. A publication covers one of the specialist areas and is normally written by a single author. When writing a particular book, each author works with an editor. The company tries to employ a variety of authors, more than one author being a specialist in a particular subject.

Upload: muhammad-nur-fateeh

Post on 01-Mar-2018

219 views

Category:

Documents


0 download

TRANSCRIPT

7/25/2019 Tutorial ER 2

http://slidepdf.com/reader/full/tutorial-er-2 1/2

:: Sem2 2015/2016 ::   ER Diagram 2 Tutoria

TT1964 Database Tutorial ER Diagram –  2 

Answer all the question based on the following steps: 

a) Identify the main entity.

 b) Identify the main relationship and specify the cardinality for each relationship.

c) Identify / create the attribute and the key attribute (if necessary)

d) Draw the complete ER

Case Study 1 

For a particular business, sales data is very important and i t’s  represented by the invoice. An

invoice written by a sales representative but each sales representative wrote many invoice. A

vendor will sell a lot of products, but the product is purchased from one vendor. In each invoicehas one or more products and products are available in zero, one or many invoices. Create your

own possible attribute for this case study. 

Case Study 2 

Azzalaeachoc Company wants to digitize employee time cards. A timecard should have hoursworked and date submitted. Each timecard is associated with exactly one employee and should

have a unique id. Each timecard has a status either approved, not approved or pending. Eachemployee has a unique id , name and address. Employee will submits a timecard every pay

 period and st ated their method of payment either direct deposit or physical check. Eachemployee is associated with exactly one manager. Each manager has a unique id and name and

he/she will in charge and approved t imecard for multiple employees. You need to help

Azzaleachoc to design the database for submitting and approving time cards with informationgiven.

Case Study 3

A Power Sey is a publishing company that produce books on various area. The books are written by authors who specialize in one particular area. The company employs editors who, not

necessarily being specialists in a particular area, each take sole responsibility for editing one or

more publications. A publication covers one of the specialist areas and is normally written by a

single author. When writing a particular book, each author works with an editor. The companytries to employ a variety of authors, more than one author being a specialist in a particular subject.

7/25/2019 Tutorial ER 2

http://slidepdf.com/reader/full/tutorial-er-2 2/2

 

Case Study 4 

Design an ER diagram for a university. The database needs to keep track of each IT Instructor withid, name, and address. Each IT Instructor works for one department and each department has at

least one IT Instructor. The departments have an id and a name. Courses are offered by a single

department and have a name, and course code unique to each department. Each course has at

least one set that store the course code, name, credits, and description. Each set will store coursecode, semester, year, and size. Students have student ids and names. Each student has a single IT

Instructor as an advisor. Students enroll in one or more sets. A set must have at least five students

or it is cancelled. A set is taught by at least one IT Instructor. Assumes each department teaches at

least one course.