FFFFF
FFFFF
FFFFF
An ABC Technical College wants to store all its information regarding the student’s
registration every term, and you as a database developer requested to design this database for
the college. This student record management system must store information about the
students and the courses enrolled. Moreover, whenever a student enrols in a course in a
specific Academic Year and Semester, the Student will have a grade for the course.
Competencies covered:
ICT DBA3 01 0811 Gather Data to Identify Business Requirements
ICT DBA3 03 0811 Design a Database
ICT DBA3 09 0811 Model Data Objects
Project 2: Install Application Software
Instruction: Under this project the candidate is expected to create a database and tables on the
information provided below.
Time for project: 50 Minutes
Prepare your machine for your project by Installing MS-SQL Server 2008
Competencies covered:
ICT DBA3 02 0811 Identify Physical Database Requirements
Project 3: Perform database operation
Instruction: Under this project the candidate is expected to create a database and tables on the
information provided below.
Time for project: 1: 40 Minutes
Task I: Create a database called “mydatabase”, and in your database create a table named
employee having fields first_name, last_name and age. Assume the maximum length of
characters for the fields ‘first_name’ and ‘last_name’ is 20 and both fields couldn’t be null.
For the age character give it appropriate data type and it could be null.
Task II: In your mydatabase database, create a table named department having fields
dep_id and dep_name. Assume the maximum length of characters for the fields ‘dep_id’ and
‘dep_name’ is 5 and 40 respectively and both fields couldn’t be null. Make dep_id the
primary key for the table.
Task III: Assume you have just started a new company. It is time to hire some employees.
You will need to create a table that will contain the following information about your new
employees: firstname, lastname, title, age, and salary.
Task IV: for already created table ‘employee’ in task I, Write SQL statements that could:
1) Add one more additional field emp_id of maximum length of characters 5 and could
have a possibility to be null.
2) Modify the maximum length of characters for the field first_name to be 15.
Competency covered
ICT DBA3 04 0811 Use Basic Structured Query Language
ICT DBA3 05 0811 Design Program Logic
ICT DBA3 06 0811 Test Physical Database Implementation
ICT DBA3 07 0811 Complete Database Backup and Recovery
ICT DBA3 08 0811 Create Technical Documentation
Answer key
Project 1: Designing a Database of Registration Record System for ABC Technical
College
Task 1- Answer:
Entities with their Attributes –
Students (Id, Name, Department, Date of Birth, Age, GPA)
Course (Course_Id, Name, Credit)
Associative Entity-
Enrolled_In (Academic_Year,Grade,Semester)
Task 2- Answer:
Possible ER diagram
USE mydatabase
CREATE TABLE myemployees
(firstname varchar(30), lastname varchar(30), title varchar(30), age tinyint, salary smallmoney);
Task IV
Answer:
A) USE mydatabase ALTER TABLE employee ADD emp_id varchar(5)
B) USE mydatabase ALTER TABLE employee ALTER COLUMN first_name
varchar(15)
Prepare your machine for your project by Installing MS-SQL Server 2008
Project 3: Perform database operation
Instruction: Under this project the candidate is expected to create a your own
database and tables on the information provided below.
Time for project: 1: 40 Minutes
Employee table
Emp_ID Emp_Fname Emp_Lname Sex Salary
E001 Kebede Asfaw M 2,680
E002 Aster Lemma F 3,100
E003 Tigist Afework F 1,890
E004 Chala Lemi M 5,250
Customer table
Cust_Id Cust_Fname Cust_Lname Cust_Address
C001 Abebe Taye Adama
C002 Chaltu Gemmechu Wonji
C003 Tesfaye Getachew Asella
C004 Bikila Alemu Modjo
Task 1: Use Basic Structured Query Language
Time allotted: - 1:00 hrs
Instruction: Under this task you are expected to perform the following queries on
the database created on project 3
Competency covered
ICT DBA3 04 0811 Use Basic Structured Query Language
ICT DBA3 05 0811 Design Program Logic
ICT DBA3 06 0811 Test Physical Database Implementation
ICT DBA3 07 0811 Complete Database Backup and Recovery
ICT DBA3 08 0811 Create Technical Documentation
A. Write a query that Insert the following record in to Employee table and save it
by the name Employee creating a folder by your name on the Desktop
Emp_Id=005
Emp_Fname=Tsegaye
Emp_Lname=Abebe
Sex=M
Salary=3,200
B. Update the salary of Kebede to 3,000 and save it by the name Kebede and
save it in your folder.
C. Write SQL statement that counts the total number of Female and Male
Employees and save it by the name Count in your folder.
D. Write SQL statement that displays all records that contains Cust_Id and
Cust_address whose customer address starts with the letter A and save it by
the name Customer Address in your Folder.
E. Delete the record from Customer table whose Cust_Id is C003 and save it by
the name Delete in your folder
Answer key
Project 1: Designing a Database for ABC Company
Task 1- Answer:
Entities-with their Attributes (database schema)
Department: Department Name (Dep_Na), Department (Dep_Na)
Employee: Employee Number (Emp_Nu), Employee Name (Emp_Na)
Supervisor: Supervisor Number (Sup_Nu), Supervisor Name (Sup_Na)
Project: Project Name (Proj_Na), Project Number (Proj_Nu)
Associative Entity-
AKPC Firaol Mengesha
Database Administration L 3 COC Project
Is_Assigned (Date_Assigned)
Works_On (Date_Begin)
Note: Date_Assigned , Date_Begine are associative attributes
Task 2- Answer:
Possible ER diagram
Time: 40 mints
The xyz is organized into departments. Each department has a unique name,a
unique number. A department may have several locations.
Each department controls a number of projects.
Each project has a unique name, unique number and depname
The database also stores Employee’s ID, Name, salary, gender, Birth Date and
department name. each employee works for one department but may work on
several projects and each project can have many employees
Instruction: under this task you are expected to perform the following activities based on the
information provided.
1. Install Microsoft office Visio 2003/7
2. Design ERD for blue nile college database based on the above given
requirements on Microsoft office Visio 2003/7
Task 2: design flowchart
Time: 20 mints
The following pseudo code describes an algorithm which accepts a number form the
keyboard and calculates the sum of numbers between 1 and N
Start
Sum =0;
Count =1;
While (count<=N)
Sum=sum+count;
End
Instruction: under this task you are expected to perform the following activities based on the
information provided.
Time: 2hrs
Instruction: you are expected to perform the following three tasks based on information
provided.
Instruction: you are expected to perform the following tasks based on information provided.
Suppose you are a database administrator in gonder blue Nile College and assigned to create
a database that manages the students, courses and students grade report information.
Instruction: under this task you are expected to perform the following activities based on the
information given.
Table 1: student
Table3: grade_report
Instruction: under this task you are expected to perform the following.
1. Develop sql query that retrieve the names of all students who score grade “B” and
save it by the name result in D: drive
2. Develop sql query that retrieves stID and name of all female students taken the course
title “database” and save it by the name “database” in desktop
3. Write sql statement that retrieves all student who score grade “A” in database
department and sort them descending by their depName and ascending by their name
and then save it by the name “ordered” in D: drive
4. Write sql statement that creates a backup for gonder bnc database and save the
backup with the backup name “gonderbncbackup” in D: drive
5. Develop sql statement that changes the section into “room9” of all students who score
grade “A” or “B” for the course title “database”
6. Assume that gonderbnc database was dropped accidentally. Write sql query that
recover dropped database form backup.
The assessor should ask oral questions on which s/he is not satisfied by yours
performance.
Competencies covered:
1. EIS DBA3 01 0811 Gather Data to Identify Business
Requirements
2. EIS DBA3 02 0811 Identify Physical Database requirements
3. EIS DBA3 03 0811 Design a Database
4. EIS DBA3 05 0811 Design Program Logic
5. EIS DBA3 08 0811 Create Technical Documentation
6. EIS DBA3 09 0811 Model Data Objects
AKPC Firaol Mengesha
Database Administration L 3 COC Project
In order to perform these activities the college needs to keep records of:
1. Trainees identified by their id, full name, sex, birth date, department, year of
entry to the college
2. Trainers identified by their id, full name, sex, educational level, field of study,
and experience, department in which the trainer is working
3. Departments (like ICT, Manufacturing, Construction, Drafting, …) identified by
their name, sector, and department establishment date
4. Competencies identified by unit code, title, total hours to complete the
competency, competency’s owner department
5. Trainee’s competency records which contain records of competencies taken
by trainee, the trainer who gives the competency to the trainee, and whether
the trainee’s result is satisfactory or unsatisfactory.
Instruction: - Based on the above scenario you are expected to perform the following
activities.
Identify Entities, Attributes, Primary Keys (PK) and Foreign Keys (FK).
Draw entity relationship(ER) diagram for the identified entities using Ms
Visio application
has dept
id
N
Name
co
Trainee
sector mp own entryYear
Uni erD 1
t ept sex
1 dBirth
openingDate
etency
Comp
total
Department
Hr has
unit
1 1 Titl
deptName owns e
1 N
has has
experience
N compUnitCode
1 N N
fieldOf Trainer
Study has
N CompetencyRecord
educLeve trainerID
l Name
sex id dept isSatisfactory
traineeID
EmpName DptName
EmpID
Employee Department
N 1
BDate
Sex has
DptID
owns
1 N
Job_Position
Salary
RequiredExp
erience
JobTitle
JobID
Instructions: Under this project you are expected to create a database Based on
the ER diagram of a registrar system database given above by
performing the following activities using MS SQL server 2005
has dept
id
N
Name
co
Trainee
sector mp own entryYear
Uni erD 1
t ept sex
1 dBirth
openingDate
etency
Comp
total
Department
Hr has
unit
1 1 Titl
deptName owns e
1 N
has has
experience
N compUnitCode
1 N N
fieldOf Trainer
Study has
N CompetencyRecord
educLeve trainerID
l Name
sex id dept isSatisfactory
traineeID
Competencies covered:
EIS DBA3 04 0811Use Basic Structured Query Language
EIS DBA3 06 0811Test Physical Database implementation
EIS DBA3 07 0811Complete Database Backup and Recovery
EmpName DptName
EmpID
Employee Department
N 1
BDate
Sex has
DptID
owns
1 N
Job_Position
Salary
RequiredExp
erience
JobTitle
JobID
Firaol Mengesha
Occupational Code: ICT Database Administration L 3 COC
Instructions: Based on the ER diagram given above, perform the following activities
using MS SQL server 2005
19. Display each department’s name along with its number of employees.
20. Delete the record of employees from employee table whose salary is less
than 3000 Birr.
21. Backup the database on a flash disk using SQL statement.
22. Restore the Database from the backup.
Acceptable answer For the assessor:
The candidate expected to do the following
3. Relationship
4. Add records
insert into Department(DptName)
values('Human Resource')
insert into Department(DptName)
values('ICT')
insert into Department(DptName)
values('Finance')
Firaol Mengesha
Occupational Code: ICT Database Administration L 3 COC
Firaol Mengesha
Occupational Code: ICT Database Administration L 3 COC
Step: 5. Browse the back up file from the flash disk and click on ‘Ok’ button.
Step: 6. Click on ‘Ok’ button
Step: 7. Under ‘Select Back up sets to restore’ click on the check box in front of
the appropriate back up set.
Step: 8. Click Ok.
Firaol Mengesha
Occupational Code: ICT Database Administration L 3 COC
Firaol Mengesha