Professional Documents
Culture Documents
Ass2 It3
Ass2 It3
Ass2 It3
#2
Academic Year 2020 – 2021 /Even Semester
(20202) Subject : Database System
Lecturer : R. B. Wahyu
Study Program : Information Technology
Class 3 Due date : May 8th 2021
Instructions to candidate:
1. This EXCERCISE paper consists of 10 pages and 3 questions.
2. You ARE NOT ALLOWED to copy the copy from your friends.
3. In all the answer you have to make different from MASTER and
TRANSACTION tables.
1. Suppose you have been given the table structure and data shown in the following
figure, which was imported from an Excel spreadsheet. The data reflect that a
professor can have multiple advisees, can serve on multiple committees, and can edit
more than one journal.
2 of 10
ii. Insert the data into all tables (masters and transactions);
iii. List the employee number and name, student number,
names and academic year for every professor;
iv. List the employee number and name, committee code,
committee names and start date for every professor in
assigned in every committe;
v. List the employee number and name, journal code, journal
name and start date for every professor who are editors in
every journal.
a)3 NF
1 of 10
b)Crow’s foot ERD
C). For all entities/tables created please write the master and transaction data accordingly
2 of 10
1. Master Data:
i. employee
ii. Department
DEPT_CODE DEPT_NAME
CIS COMP. TECHNOLOGY
CHEM CHEMISTRY
ENG ENGLISH
iii. Student
STUDENT_NAME STUDENT_NUM
AKBAR 1324
BAGAS 2312
RAEL 3102
SURYA 2782
BAGUS 2134
SHELINE 2786
JONO 3456
AHMAD 2873
JAJANG 9866
BUDI 2085
3 of 10
iv. Committee
COMMITTEE_NAME COMMITTEE_CODE
PROMOTION PROMO
TRAFFIC TRAF
APPLICATION APP
DEVELOPMENT DEV
SUPERIOR SPR
JOURNAL_CODE JOURNAL_NAME
JMIS JOURNAL IN MANAGEMENT INFORMATION SYSTEMS
QED QUALITY IN EDUCATION
JMGT JOURNAL OF MANAGEMENT
JCIS JOURNAL IN COMPUTER INFORMATION SYSTEMS
4 of 10
2. Transaction Data:
i. Advisee
ii. Assignment
iii. Editor
5 of 10
6 of 10
D. Create the DATABASE for this schema then do the following
(Please print screen /the SQL STATEMENTS FOR all the
following activities):
vi. For all entities please CREATE the tables;
7 of 10
vii. Insert the data into all tables (masters and transactions);
Master Data
Employee
Student
8 of 10
Department
committee
9 of 10
Journal
Transactions Data
Advisee
10 of
10
Assignment
Editor
11 of
10
viii. List the employee number and name, student number,
names and academic year for every professor;
12 of
10
x. List the employee number and name, journal code, journal
name and start date for every professor who are editors in
every journal.
13 of
10
a. ALL TABLES CONFORM TO 3NF
1. EMPLOYEE
2. DEPARTMENT
DEPT_CO DEPT_NAM
DE E
PK
3. STUDENT
STUDENT_NU STUDENT_NAM
M E
PK
4. COMMITTEE
COMMITTEE_CO COMMITTEE_NA
DE ME
PK
14 of
10
5. JOURNAL
JOURNAL_CO JOURNAL_NA
DE ME
PK
6. ADVISEE
7. ASSIGNMENT
8. EDITOR
15 of
10
b. UNIVERSITY CROW’S FOOT ERD
4 of 10
c. MASTERS AND TRANSACTIONS DATA
MASTER DATA:
1. EMPLOYEE
2. DEPARTMENT
DEPT_CO DEPT_NAME
DE
CIS COMPUTER INFOR.
SYSTEMS
CHEM CHEMISTRY
ENG ENGLISH
3. STUDENT
STUDENT_NU STUDENT_NAME
M
1215 GHEE STD1
2312 GHEE STD2
3232 GHEE STD3
2218 GHEE STD4
2098 GHEE STD5
3102 RANKIN STD1
2782 RANKIN STD2
3311 RANKIN STD3
2008 RANKIN STD4
2876 RANKIN STD5
2222 RANKIN STD6
3745 RANKIN STD7
1783 RANKIN STD8
2378 RANKIN STD9
2134 ORTEGA STD1
2786 ORTEGA STD2
3456 ORTEGA STD3
2002 ORTEGA STD4
5 of 10
2046 ORTEGA STD5
2018 ORTEGA STD6
1764 ORTEGA STD7
6 of 10
2873 SMITH STD1
2765 SMITH STD2
2238 SMITH STD3
2901 SMITH STD4
2308 SMITH STD5
4. COMMITTEE
COMMITTEE_CO COMMITTEE_NA
DE ME
PROMO PROMOTION
TRAF TRAFFIC
APPL APPLICATION
DEV DEVELOPMENT
SPR SUPERIOR
5. JOURNAL
JOURNAL_CO JOURNAL_NA
DE ME
JMIS JOURNAL IN MANAGEMENT INFORMATION
SYSTEMS
QED QUALITY IN EDUCATION
JMGT JOURNAL OF MANAGEMENT
JCIS JOURNAL IN COMPUTER INFORMATION
SYSTEMS
TRANSACTIONS/RELATIONAL DATA:
6. ADVISEE
8 of 10
104 2222 2020-2021
104 3745 2020-2021
104 1783 2020-2021
104 2378 2020-2021
118 2134 2020-2021
118 2786 2020-2021
118 3456 2020-2021
118 2002 2020-2021
118 2046 2020-2021
118 2018 2020-2021
118 1764 2020-2021
119 2873 2020-2021
119 2765 2020-2021
119 2238 2020-2021
119 2901 2020-2021
119 2308 2020-2021
7. ASSIGNMENT
8. EDITOR
9 of 10
2. All of you must be part of a family. So please design a database for a FAMILY
system that at leat has 5 entities/relationships which consist of activities and or
services that you familiy doing for the 5 entities please do the following. The
database should record the names of your greater family, their activities, and the
services that they received (for example your uncle go a gymnastic at least twice a
week or watch movies etc...).
a. Create all tables that conform to 3NF;
b. Draw a Crow’s Foot ERD for the database;
c. Writed own the Masters and Transactions tables. For every
transaction table, write down at least 10 (ten) tuples data and for 3
persons shows that they go to the same activities/services at least
twice!
1. CITIZEN
2. CITY
CITY_ID CITY_NAME
P
3. GENDER
K
GENDER_I GENDER
D P
K
4. ACTIVITY
5. SERVICE
11 of 10
6. ACTIVITY_DETAILS
7. SERVICE_DETAILS
1. Masters:
a. Citizen
12 of 10
3 SALVA 17 28/01/2006 M SISTER
4 HAMKA 25 3/10/2003 M BROTHER
5 GITA 87 13/9/1993 F STEPSISTER
6 DIMAS 35 30/7/1995 M DISTANT BROTHER
7 AKBAR 67 12/02/2001 M STEPBROTHER
8 GOZI 87 2/6/2015 M DISTANT BROTHER
b. City
CITY_ID CITY_NAME
12 PATI
17 BEKASI
87 CIAMIS
c. Gender
GENDER_CODE GENDER
M MALE
F FEMALE
d. Activity
e. Service
13 of 10
32 HAIR CUTS 120,000
33 MASSAGE 150,000
34 SHIPING 350,000
2. Transactions:
a. Activity Details
b. Service Details
ii. Insert the data into all tables (masters and transactions);
MASTER DATA
(GENDER)
ACTIVITY
SERVICE
15 of 10
iii. List citizen id, citizen name, activity id, activity name, activity date for every
activity occurs;
iv. List citizen id, citizen name, service id, service name, quantity, unit price,
sub_total for every service occurs;
v. Update (add/substract/divide/multiply) an attribute value (the attribute has
numerical/integer value) of 2 records and then List citizen id, citizen name,
service id, service name, quantity, unit price, sub_total for every service occurs;
vi. List citizen id, citizen name, service id, service name, quantity, unit price,
sub_total for every order that have more than one orders from the citizens.
3. All of you must be familiar with KOPERASI (CREDIT UNION) business activities and
environment. So please design database for a KOPERASI system that at least has 4 entities
16 of 10
involved and for the 4 entities please do the following:
a. Create all tables that conform to 3NF;
1. MEMBER
POS_NAME POS_NAME
P
K
17 of 10
3. SAVING
SAVING_CODE SAVING_TOTAL
P
K
4. LOAN
18 of 10
c. Writed own the Masters and Transactions tables. For every transaction table,
write down at least 10 (ten) tuples data and for 3 MEMBERS shows that they
borrow the money at least twice!
MASTER DATA :
1. MEMBER
19 of 10
MEM_NUM MEM_NAME POS_ID SAVING_COD LOAN_CODE
E
1 ADEL PM 111 101
2 RAZIQ VPM 112 102
3 AFNI SECRE 113 103
4 ERVA VSECRE 114 104
5 HANA TREA 115 105
6 AISYAH VTREA 116 106
7 RERE MEM 117 107
8 ISAL MEM 118 108
9 FAUZAN MEM 119 109
10 SIKA MEM 120 110
2. POSITION
POS_ID POS_NAME
PM PROJECT MANAGER
VPM VICE PM
SECRE SECRETARY
VSECRE VICE SECRETARY
TREA TREASURER
VTREA VICE TREASURER
MEM MEMBER
TRANSACTION DATA:
3. SAVING
SAVING_CODE SAVING_TOTAL
111 100.000
113 500.000
115 500.000
117 350.000
120 200.000
4. LOAN
20 of 10
LOAN_CODE LOAN_TOTA DATE
L
102 150.000 03-05-2021
102 200.000 04-05-2021
104 100.000 03-05-2021
104 50.000 04-05-2021
106 70.000 03-05-2021
106 130.000 04-05-2021
108 120.000 05-05-2021
d. Create the DATABASE for this schema then do the following (Please print
screen
/the SQL STATEMENTS FOR all the following activities):
i. For all entities please CREATE the tables;
ii. Insert the data into all tables (masters and transactions);
iii. List member number, member name, amount borrow, the date of
borrow from all members;
21 of 10
v. List member number, member name, payment amount, the date of
payment from all members.
Good luck
22 of 10