Download as pdf or txt
Download as pdf or txt
You are on page 1of 29

DATABASE DESIGN CONCEPTS

INTERNATIONAL HIGHER DIPLOMA IN COMPUTER NETWORKS


ASSIGNMENT BRIEF

EdHat Registration Number

Candidate Name W.G. Isuru Vishwajith Jayasingha

Module Code / Module Title ITC 0202 / DATABASE DESIGN CONCEPTS

Assignment title LOWSON SUMMER HOUSES

Summary of Learning outcomes covered

• LO1 - Understand Database Environment


• LO2 - Use and manipulate appropriate database software
• LO3 - Design a database
• LO4 - Demonstrate the use of database

Assignment Type : Individual Assignment

Issued Date : 10/02/2021

Due Date : 17/04/2021

Date Submitted : 16/04/2021

Assessor : Mrs. Inoka Herath

Internal Verifier :

PLAGIARISM:

While research and discussion are an essential part of an assignment, the deliberate copying of
someone else’s work or unacknowledged copying from printed or electronic sources is NOT
permitted. You may be subject to disciplinary procedure if you do this. You should sign this sheet
to show that you comply with these regulations.

Student’s Signature: Date: _____/_____/ __________


EdHat International Higher Diploma in Computer Networks
Assignment Brief - Cover Sheet
Version: 2020.1.1
DATABASE DESIGN CONCEPTS

EdHat International Higher Diploma - Assignment Grading Sheet

Mark Range Grade Point Grading Representation


0 - 29 0.0 E

30 - 39 1.0 D

40 - 49 1.7 C-

50 - 54 2.0 C

55 - 59 2.3 B-

60 - 64 2.7 B

65 - 69 3.0 B+

70 - 74 3.3 A-

75 - 79 3.7 A

80 and above 4.0 A+

Task 01 – Marks Task 02 – Marks Task 03 – Marks Total Marks

Grade Point
Final Grade
Total Marks (Average above / overall grading)

Assessor Comments:

Assessor:
Signature: Date:_____/_____/ ___________
DATABASE DESIGN CONCEPTS
Internal Verifier Comments:

IV Name: Date:_____/_____/ ___________


Signature:
DATABASE DESIGN CONCEPTS

Introduction
This assignment is in four parts, design, data and queries, derived data and an evaluation. All
parts of the assessment relate to the Lawson Summer Houses scenario below.

Scenario
Lawson Summer Houses are a construction company based in the UK. The company
specialize in building summer houses and outbuildings such as sheds. They want you to
design and implement a database that meets the requirements for their data. These
requirements are specified in this scenario and the examples of paper documents kept by the
company that are shown below.

Lawson Summer Houses organise their data around the concept of a ‘job’. A job is specified
as being for a particular property; but note that a property might have more than one job over
time.

A job is also categorized by job type which is linked to a particular design. The detailed
architectural plans for each design are NOT to be stored on this database. Instead a design
would be linked to a number of parts and there should be a reference to a detailed plan kept
as a separate document. Moreover, a particular design will specify the parts to be used for that
design. A separate record is kept of the actual parts used on that job, which will include any
additional parts used beyond those specified in the design. This is shown in the sample
documents below. Finally, there should also be a record kept of the members of staff who work
on a job.

Please Note: The data shown in the assignment is not necessarily normalised, and that it is
the candidate’s task to organize the data in the most optimal way possible. For example, the
paper records shown below will not necessarily map directly to data base tables. The candidate
is expected to use these tables as a starting point for their own normalisation and optimisation
of the Lawson Summer Houses data.

Please note also that all SQL scripts should be shown along with their results.

Page 1 of 5
DATABASE DESIGN CONCEPTS

Below is a sample of the paper records currently kept by Lawson Summer Houses Document

1 – Initial Job Sheet at outset of a job


Parts
Job ID Property Id Address Job Type Design specified in
Design
2 x Long side
wall fittings 1
x Back
23 The
Summer wall fittings 1
Elms, Summer x front wall
2 234 House Type
Andover, House
2 fittings
Hants.
8 x window
fittings

2 x short side
wall fittings
1 x Back
Rapid wall fittings 1
Summer
House Summer x front wall
6 343 House Type
Gardens, House fittings
8
Essex 6 x window
fittings

99 Neat Standard
7 600 Street, Utility Shed Shed Type 1 Shed pack
Chesire.

Document 2 – Staff on Job Record


Staff
Job ID Number Name
2 S1 Isla St Cloud
2 S8 Zak Dodd
2 S2 Marco Yad
6 S11 Sally Lam
6 S1 Isla St Cloud
7 S8 Zak Dodd
7 S1 Isla St Cloud

Page 2 of 5
DATABASE DESIGN CONCEPTS

Document 3 – Final Job Record


Parts used
as specified
Property in Additional Parts
Job ID Design
Id used on job
Design

2 x Long
side wall
fittings 1 x
Back wall 1 x Base Board
fittings 1 x 12 x filters for
Summer House front wall water pump 1 x
2 234 fittings
Type 2 addition
8x al window
window frame
fittings

2 x short
side wall
fittings 1 x
Back wall
fittings 1 x
front wall 1 x
Summer House
6 343 fittings additional
Type 8
6x window frame
window
fittings

Standard Shed
7 600 Shed Type 1 pack 1 x door pelmet

Page 3 of 5
DATABASE DESIGN CONCEPTS

Task 01: Initial Design (LO1) Allocated Given


Marks Marks
Create an entity relationship model for the proposed database 75
system for Lawson Summer Houses. This should be a fully
normalised model to 3rd normal form. You do not have to show
the steps you took in the normalisation process.

Create a data dictionary for the entity relationship model 25

Task 02: Data and Queries (LO2) Allocated Given


Marks Marks
Create all the tables using SQL. Show your Create scripts and the 30
finished tables.
• Input data on all the jobs and the properties for those jobs.
• Provide a listing of this Input data for the members of staff
including those listed in the scenario. Enter yourself as a
member of staff and assign staff to jobs.
• Provide a listing of this Input data on the parts that belong
to a particular design and the parts that are actually used
on a job. Provide a listing of this.

• Write a query that selects all the jobs and which staff have 70
worked on them.
• Write a query that selects the parts that are actually used
on a job including those specified as standard in the design
for that particular job.
• Write a query that selects all the properties and the jobs
that have taken place at those properties.
• Write a query that shows all jobs that have taken place for
a particular design.
• Write a query that counts the number of jobs that have used
a back wall fitting.
• Write a query that shows all the summer house jobs that a
particular member of staff has worked on

Page 4 of 5
DATABASE DESIGN CONCEPTS

Task 03: Derived Data and Evaluation (LO3 and LO4) Allocated Given
Marks Marks
The company have said they would like to extend the database 60
to include costing information. All parts will be allocated a price
and all members of staff a flat rate for working on a job.

Discuss how you would derive data for a report that showed all
the relevant data for a job including the costs. This should also
include the property, job type, design, parts and staff. You should
include an outline of how you would derive it using SQL and
specify the method of implementing it

Give an evaluation of how the work you have done has met the 40
requirements of the firm. This should include data storage and
applications. You should also discuss how you have standardised
the company’s data.

Submission Requirements

• Your submission should be in the form of a single word-processed document that


includes any necessary diagrams.
• The word count for the document is 1750 words (excluding text in any diagrams).
You should explain any assumptions you have made.
• A digital version must be submitted on a CD, USB flash drive or other similarly
acceptable medium, along with a copy of the developed database.

Page 5 of 5
DATABASE DESIGN CONCEPTS

Table of Contents

Table of Figures. ........................................................................................................................ 7

Introduction. ............................................................................................................................... 8

TASK 01 .................................................................................................................................... 9

TASK 02 ...................................................................................................................................12

TASK 03 ...................................................................................................................................20

Conclusion. ...............................................................................................................................24

Gantt Chart. ..............................................................................................................................25

Page | 6
DATABASE DESIGN CONCEPTS

Table of Figures.
Figure 1 ____________________________________________________________________ 9
Figure 2 ___________________________________________________________________ 13
Figure 3 ___________________________________________________________________ 14
Figure 4 ___________________________________________________________________ 14
Figure 5 ___________________________________________________________________ 15
Figure 6 ___________________________________________________________________ 15
Figure 7 ___________________________________________________________________ 16
Figure 8 ___________________________________________________________________ 17
Figure 9 ___________________________________________________________________ 17
Figure 10 __________________________________________________________________ 18
Figure 11 __________________________________________________________________ 18
Figure 12 __________________________________________________________________ 19
Figure 13 __________________________________________________________________ 20
Figure 14 __________________________________________________________________ 21

Page | 7
DATABASE DESIGN CONCEPTS

Introduction.
This assignment about database design. We must create a database for Lawson Summer
Houses company. it is a construction company based in the UK. First, we have to drawing a
ERD and relational schema. After, we must normalize it and create a data dictionary for it. After
create our logical view of our database we must design database using SQL. we need to create
table and insert data and showing data and also, we have to update existing tables and insert
new columns them. at last we must create a table for accounting part and write a report to our
database.

Page | 8
DATABASE DESIGN CONCEPTS

TASK 01: Initial Design.


Create an entity relationship model for the proposed database system for
Lawson Summer Houses. This should be a fully normalised model to 3rd
normal form. You do not have to show the steps you took in the normalisation
process.

Figure 1

This is the entity relationship model which I was design for Lawson Summer Houses company. I
was assumed that each type of the summer houses and each type of the utility shed are always
using specified parts planed before it. when building that type of summer houses and sheds are
using part specified and if it want additional parts then its added. Also, additional parts and used
parts that used while building them, recorded in the database.

Page | 9
DATABASE DESIGN CONCEPTS

Relational schema.
Job (JobID, PropertyID, Design, PartsUsed, AdditionalParts)

Property (PropertyID, Address)

Proposal (Design, JobType, PartsSpecified)

JobStaff (JobID, StaffNum)

Staff (StaffNum, StaffName)

3rd NF

Job Property Proposal


JobID PropertyID Design
PropertyID Address JobType
Design PartsSpecified
PartsUsed
AdditionalParts

JobStaff Staff
JobID StaffNum
StaffNum StaffName

Page | 10
DATABASE DESIGN CONCEPTS

Create a data dictionary for the entity relationship model.

Field Name Data Type Field Length Constraint Description

Job
JobID INT 5 Primary Key Job ID, way to
recognize a job.
PropertyID INT 5 Foreign Key Property ID, way to
recognize a
property.
Design VARCHAR 30 Foreign Key What is the type of
house or shed?
PartsUsed VARCHAR 255 Not Null Parts used when
building
AdditionalParts VARCHAR 255 Not Null Parts that used
additionally for the
design.
Property
PropertyID INT 5 Primary Key Property ID, way to
recognize a property
Address VARCHAR 255 Not Null A way to recognize
the property.
JobStaff
JobID INT 5 Composite Key Job ID, way to
recognize a job.
StaffNum VARCHAR 10 Composite Key A way to recognize
staff members.
Staff
StaffNum VARCHAR 10 Primary Key A way to recognize
staff members.
StaffName VARCHAR 50 Not Null Staff members
names
Plan
Design VARCHAR 30 Primary Key What is the type of
house or shed?
JobType VARCHAR 30 Not Null Type of a job

PartsSpecified VARCHAR 255 Not Null Common parts that


using to the design

Page | 11
DATABASE DESIGN CONCEPTS

TASK 02: Data and Queries.


Create all the tables using SQL. Show your Create scripts and the finished
tables.
• Input data on all the jobs and the properties for those jobs.
• Provide a listing of this Input data for the members of staff including
those listed in the scenario. Enter yourself as a member of staff and
assign staff to jobs.
• Provide a listing of this Input data on the parts that belong to a
particular design and the parts that are actually used on a job.
Provide a listing of this.

Creating Database.
CREATE DATABASE LawsonSummerHouses;

Creating Tables.
USE LawsonSummerHouses;

CREATE TABLE Property


(
PropertyID INT NOT NULL PRIMARY KEY,
Address VARCHAR(50)
);

CREATE TABLE Proposal


(
Design VARCHAR(50) NOT NULL PRIMARY KEY,
JobType VARCHAR(50),
PartsSpecified VARCHAR(200)
);

CREATE TABLE Staff


(
StaffNum VARCHAR(30) NOT NULL PRIMARY KEY,
StaffName VARCHAR(50),
);

Page | 12
DATABASE DESIGN CONCEPTS

CREATE TABLE Job


(
JobID INT NOT NULL PRIMARY KEY,
PropertyID INT NOT NULL FOREIGN KEY
REFERENCES Property(PropertyID),
Design VARCHAR(50) NOT NULL FOREIGN KEY
REFERENCES Proposal(Design),
PartsUsed VARCHAR(200),
AdditionalParts VARCHAR9200)
);

CREATE TABLE JobStaff


(
JobID INT NOT NULL FOREIGN KEY
REFERENCES Job(JobID),
StaffNum VARCHAR(30) NOT NULL FOREIGN KEY
REFERENCES Staff(StaffNum)
PRIMARY KEY (JobID, StaffNum)
);

Insert Data.
INSERT INTO Property
VALUES
(234, '23 The Elms, Andover, Hants.'),
(343, 'Rapid House Gardens, Essex.'),
(600, '99 Neat Street, Chesire.');

Figure 2

Page | 13
DATABASE DESIGN CONCEPTS

INSERT INTO Proposal


VALUES
('Summer House Type 2', 'Summer House',
'2 x Long side wall fittings 1 x Back wall fittings 1 x front wall fittings 8 x window fittings'),
('Summer House Type 8', 'Summer House',
'2 x short side wall fittings 1 x Back wall fittings 1 x front wall fittings 6 x window fittings'),
('Shed Type 1', 'Utility Shed', 'Standard Shed pack');

Figure 3

INSERT INTO Staff


VALUES
('S1 ','Isla St Cloud'),
('S8', 'Zak Dodd '),
('S2', 'Marco Yad'),
('S11', 'Sally Lam');
Figure 4

INSERT INTO Job


VALUES
(2, 234, 'Summer House Type 2','2 x Long side wall fittings 1 x Back wall
fittings 1 x front wall fittings 8 x window fittings','1 x Base Board 12 x
filters for water pump 1 x additional window frame'),
(6, 343, 'Summer House Type 8', '2 x short side wall fittings 1 x Back
wall fittings 1 x front wall fittings 6 x window fittings','1 x
additional window frame'),
(7, 600, 'Shed Type 1 ', 'Standard Shed pack', '1 x door pelmet');

Page | 14
DATABASE DESIGN CONCEPTS

Figure 5

INSERT INTO JobStaff


VALUES
(2, 'S1'),
(2, 'S8'),
(2, 'S2'),
(6, 'S11'),
(6, 'S1'),
(7, 'S8'),
(7,'S1'); Figure 6

Page | 15
DATABASE DESIGN CONCEPTS

• Write a query that selects all the jobs and which staff have worked on
them.
• Write a query that selects the parts that are actually used on a job
including those specified as standard in the design for that particular
job.
• Write a query that selects all the properties and the jobs that have
taken place at those properties.
• Write a query that shows all jobs that have taken place for a particular
design.
• Write a query that counts the number of jobs that have used a back-
wall fitting.
• Write a query that shows all the summer house jobs that a particular
member of staff has worked on

SELECT * FROM Job;


SELECT * FROM JobStaff;

Figure 7

Page | 16
DATABASE DESIGN CONCEPTS

SELECT Job.JobID, Job.PartsUsed, Proposal.PartsSpecified


FROM Job
INNER JOIN Proposal
ON Job.Design=Proposal.Design;

Figure 8

SELECT JobID,PropertyID
FROM Job;

Figure 9

Page | 17
DATABASE DESIGN CONCEPTS

SELECT JobID
FROM Job
WHERE Design= 'Summer House Type 8';

Figure 10

SELECT COUNT(JobID)
FROM Job
WHERE PartsUsed LIKE '%Back wall fitting%';

Figure 11

Page | 18
DATABASE DESIGN CONCEPTS

SELECT Proposal.Design, Job.JobID


FROM Proposal
INNER JOIN Job
ON Proposal.Design=Job.Design
WHERE JobType= 'Summer House';

Figure 12

Page | 19
DATABASE DESIGN CONCEPTS

TASK 03: Derived Data and Evaluation.


The company have said they would like to extend the database to include
costing information. All parts will be allocated a price and all members of
staff a flat rate for working on a job.
Discuss how you would derive data for a report that showed all the relevant
data for a job including the costs. This should also include the property, job
type, design, parts and staff. You should include an outline of how you
would derive it using SQL and specify the method of implementing it

ALTER TABLE JobStaff ADD Salary MONEY;

UPDATE JobStaff SET Salary=3000 WHERE JobID= 2;


UPDATE JobStaff SET Salary=3000 WHERE JobID= 6;
UPDATE JobStaff SET Salary=3000 WHERE JobID= 7;

Figure 13

CREATE TABLE Account


(
JobID INT NOT NULL FOREIGN KEY
REFERENCES Job(JobID),
CostID INT NOT NULL PRIMARY KEY,
AllUsedParts VARCHAR(250) NOT NULL,
PartsCost MONEY,
SalaryCost MONEY,
FinalCost MONEY
);

Page | 20
DATABASE DESIGN CONCEPTS

INSERT INTO Account


VALUES
(2, 001,'2 x Long side wall fittings, 1 x Back wall
fittings, 1 x front wall fittings, 8 x window fittings, 1 x Base Board, 12 x
filters for water pump, 1 x additional window frame', 25000, 9000, 34000),
(6, 002,'2 x short side wall fittings, 1 x Back
wall fittings, 1 x front wall fittings, 6 x window fittings, 1 x
additional window frame',15000,6000,21000),
(7,003,'Standard Shed pack, 1 x door pelmet', 10000,
6000,16000);

SELECT Job.JobID, Job.PropertyID, JobStaff.StaffNum, Job.Design,


Proposal.JobType, Account.AllUsedParts, Account.FinalCost
FROM Job
INNER JOIN Proposal ON Job.Design= Proposal.Design
INNER JOIN JobStaff ON Job.JobID= JobStaff.JobID
INNER JOIN Account ON Job.JobID=Account.JobID
WHERE Job.JobID=2;

Figure 14

Page | 21
DATABASE DESIGN CONCEPTS

While creating account table,


• I was assumed after done one job an employee who work that job gets 2000-dollar
salary.
• Also, all used parts costs were assumed according market price.
• The Final cost includes only all salary cost that are spend on one job and all used parts
prices.

Page | 22
DATABASE DESIGN CONCEPTS

Give an evaluation of how the work you have done has met the
requirements of the firm. This should include data storage and applications.
You should also discuss how you have standardised the company’s data.

Lawson Summer Houses organise their data around the concept of a ‘job’. Therefore, Job is the
main entity in database. also, they have more than one job in one property. they have specified
parts to their designs. while job, they use parts that what are specified before and also use
additional parts. the staff members are working multiple job in a same time.
So, in the first scenario there are 5 main entities. first, I was provided EDR and relational
schema to the company Database. after I was use 3rd normalization to normalize it. After these
all steps I was create a database using SQL.
The database is fully normalized and a relational database. the company can store effectively
their data using this database. all of company requirements are firm this scenario. Also, they
can get report their jobs using single query. the database provides all of the data relevant the
'job'.
I was used physical storage device to store database. But also, if company want, they can use
cloud storage. In this case, I was use Microsoft SQL server management studio 2019 to create
this database.
I was use simple few steps to standardised the company’s data,
01. I was found correct, clear and complete data about the company requirements. After, I
was verified data what I had, using attached documents in the question.
02. I was removed clutter of Database. that's include duplicate data, irrelevant data,
redundant data, inaccurate data and low-quality data. that's called normalization. In this
database has 3rd normalization.
03. In this step I was Consider what is business requirements when collecting data. What
data do I absolutely need to collect? What data is less important for this business
processes?
04. In this step I was consider about SQL queries restrictions and I always try to code
correct and simple SQL queries to create this database. Also, I was used professional
methods to create this database.
In large databases, it is impossible to avoid quality and standardization issues at some level.
But by making standardization and proper data collection a priority, you’ll greatly reduce the
amount of time that you have to spend dealing with these issues.

Page | 23
DATABASE DESIGN CONCEPTS

Conclusion.
This assignment is providing a lot of important data about design a database. Also, we can get
good knowledge about SQL language. I was research about this topic and found lot of important
thing to how we can design a good database and how to create and maintain database using
SQL. therefore, who study this assignment they can get good knowledge about database
management. Also, we can get idea about how to design database for a normal company.

Page | 24
DATABASE DESIGN CONCEPTS

Gantt Chart.
Deadline – 17.04.2021

TASK 01

TASK 02

TASK 03

TASKS
2021.04.10

2021.04.11

2021.04.12

2021.04.13

2021.04.14

2021.04.15

2021.04.16
Dates

Page | 25
DATABASE DESIGN CONCEPTS

Declaration of Academic Honesty


Instructions

1. You must submit a completed copy of this form every time you submit an assignment.
2. You must submit this declaration electronically, either within your assignment, file, or as a
separate file.
3. If you do not submit this declaration, your work will not be assessed.
4. If any student is found to have been dishonest, then the student may face disciplinary action
as stated in the Nations Campus Plagiarism Policy.

Student’s Full Name: W.G. Isuru Vishwajith Jayasingha

Date: 17.04.2021

Assignment Title: DATABASE DESIGN CONCEPTS

Declaration (Insert YES or NO here): YSE

1. I confirm that this assignment is my own work:

2. I confirm that where ever I have used someone else’s words, concepts, graphics or data in
my work, I have clearly indicated exactly where I have done so, using the Oscola referencing
system. (insert yes or no here):

3. I confirm that I have indicated by referencing, where I have used someone else’s words,
concepts, graphics or data, irrespective of whether I have quoted verbatim or I have
paraphrased in my own words.

4. I have clearly indicated in my assignment any work that has been contributed by another
student.

5. I have clearly indicated in my assignment any work that has been carried out collaboratively
with another student.

……………………………………………..

Student Signature

EdHat International Higher Diploma Assignment Page | 26


Student Academic Honesty Statement
Version: 1.1(2020)

You might also like