Database Design and Implementation
Database Design and Implementation (M31994 & M32275)
Coursework 2: Modelling and querying in SQL
Unit coordinator: Frank Nguyen
Accounting & Financial Management Subject Group
This is an individual assignment and carries [50%] of the module mark and the
maximum word count is 1,500 words. It covers the following learning outcomes for
the module:
Understand the role of databases in an organisation
Understand relational databases & structured data
Critically design and implement relational database given dataset and requirements
Be able to create and query databases using SQL
Staples and All Ltd. company (SAA) is an office supplies company. Their customers range from big companies to small and medium companies, and operate across the UK.SAA has been in the market for over 20 years and their business has seen tremendous growth recently. As the market is very competitive, it is vital for executives to have various performance reports quickly and accurately so that they can make decisions accordingly.
A group owner is a relationship manager (salesman) who is responsible for some group companies. There are approximtely 20 group owners responsible for over 200 group companies.
Similarly, a division owner is responsible for divisions. Typically a division owner serves divisions within one location/city. There are approximately over 100 division owners to serve customers spreading across the UK. A product owner is a salesman who is responsible for a specific line of product. For example, a customer can purchase papers and pens: there will be one product owner for papers and a different product owner for pens.
An employee can have multiple jobs: a group owner, division owner and/or product owner at the same time
There are three layers of products, the highest level is Product Section, followed by Product Category and down to the smallest is individual item (Article).
For each line in the Raw, there are:
Quantity: number of the respective item ordered
Price: price of the item
Amount: multiplication of quantity and price.
Note: the DivisionID has been invented years ago and no longer suitable to uniquely
identify a division. You may need to use DivisionName along with GroupName for
that purpose.
Requirements:
1. Draw the fully labelled and implementable Crow’s Foot ERD based on your findings above. Include all entities, relationships, optionalities, connectivities, and cardinalities. (20 marks)
2. Implement your ERD in MySQL. (20 marks)
3. Write a management report which address the following questions:
3.1 Total revenue SAA made during the period from 01/01/2017 to
31/12/2017 (5 marks)
3.2 Monthly sales for the same period (5 marks)
3.3 The top 5 popular products/articles per:
(1) quantity and
(2) total revenue during the period. (10 marks)
3.4 Total number of items (quantity) sold per quarter during the same period for:
(1) the whole SAA and
(2) per customer (group level only) (only include the top five and bottom five group customers in your main report) (10 marks)
3.5 Top three biggest customers (Group level) purchased during the same period.
For all those three customers, which three divisions have the highest sales. (10 marks)
3.6 The top 5 best performance group owners and product owners during the same period (10 marks)
3.7 Presentation (clear headings, easy to understand to non–technical users e.g. use of charts) (10 marks)