Docsity

ASM2 - 1622 Database programming, Assignments of Database Programming

Toggle sidebar
bg1
1
ASSIGNMENT 2 FRONT SHEET
Qualification
TEC Level 5 HND Diploma in Computing
Unit number and title
Unit 04: Database Design & Development
Submission date
Date Received 1st submission
Re-submission Date
Date Received 2nd submission
Student Name
Le Nguyen Quang Nam
Student ID
GCD201654
Class
GCD0905
Assessor name
Do Duy Thao
Student declaration
I certify that the assignment submission is entirely my own work and I fully understand the consequences of plagiarism. I understand that
making a false declaration is a form of malpractice.
Student’s signature
Le Nguyen Quang Nam
Grading grid
P2
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e
pf1f
pf20
pf21
pf22
pf23
pf24
pf25
pf26
pf27
pf28
pf29
pf2a
pf2b
pf2c
pf2d
pf2e
pf2f
pf30
pf31
pf32
pf33
pf34
pf35
pf36
pf37
pf38
pf39
pf3a

Partial preview of the text

Download ASM2 - 1622 Database programming and more Assignments Database Programming in PDF only on Docsity!

ASSIGNMENT 2 FRONT SHEET

Qualification TEC Level 5 HND Diploma in Computing

Unit number and title Unit 04: Database Design & Development

Submission date Date Received 1st submission

Re-submission Date Date Received 2nd submission

Student Name Le Nguyen Quang Nam Student ID GCD

Class GCD0905 Assessor name Do Duy Thao

Student declaration

I certify that the assignment submission is entirely my own work and I fully understand the consequences of plagiarism. I understand that

making a false declaration is a form of malpractice.

Student’s signature Le Nguyen Quang Nam

Grading grid

P2 P3 P4 P5 M2 M3 M4 M5 D2 D

❒ Summative Feedback: ❒ Resubmission Feedback:

Grade: Assessor Signature: Date:

Signature & Date:

  1. Technical document.

1.1 Introduction................................................................................................................................................ 44

1.2 User requirement........................................................................................................................................ 44

1.3 Diagram...................................................................................................................................................... 45

1.4 Possible and realistic improvement........................................................................................................... 46

1.5 Current version number.............................................................................................................................. 46

1.6 Date last changed and implemented.

  1. User document.................................................................................................................................................... 47

REFERENCE LIST...................................................................................................................................................... 58

TABLE OF FIGURES

Figure 1_. The main interface of the system._ .......................................................................................................... 10

Figure 2_. Menu of view option._ .............................................................................................................................. 11

Figure 3_. View Provider list._

Figure 4_. View Customer list._ ................................................................................................................................ 13

Figure 5_. View Drug list._ ....................................................................................................................................... 14

Figure 6_. View Order list._

Figure 7_. View Order detail list._ ........................................................................................................................... 16

Figure 8_. Menu of Add option._ .............................................................................................................................. 17

Figure 9_. Menu of Update option._

Figure 10_. Menu of Statistic option._ ...................................................................................................................... 20

Figure 11_. Creating the database._ ........................................................................................................................ 20

Figure 12_. Creating Provider table._

Figure 13_. Creating Drug table._ ............................................................................................................................ 21

Figure 14_. Creating Customer table._ .................................................................................................................... 22

Figure 15_. Creating Order table._ .......................................................................................................................... 22

Figure 32_. Select all tables._

Figure 33_. The information of Provider table._ ...................................................................................................... 32

Figure 34_. The information of Drug table._ ............................................................................................................ 33

Figure 35

. The information of Customer table. .................................................................................................... 33

Figure 36_. The information of Order table._ .......................................................................................................... 34

Figure 37_. The information of OrderDetail table._ ................................................................................................ 35

Figure 38_. Updating data of a customer._

Figure 39_. Data before updating._ .......................................................................................................................... 36

Figure 40_. Data after updating._ ............................................................................................................................ 36

Figure 41_. Deleting data from tables._ ................................................................................................................... 37

Figure 42_. Before deleting data._ ............................................................................................................................ 37

Figure 43_. After deleting data._

Figure 44_. Deleting table._ ...................................................................................................................................... 38

Figure 45_. Query to find the best-seller drug._ ....................................................................................................... 38

Figure 46_. Result of the best-seller drugs._

Figure 47_. Query to find the drugs that are least bought._ .................................................................................... 39

Figure 48_. Result of the drugs that are least bought._

Figure 49_. Query to find out the day has highest revenue._ ................................................................................... 39

Figure 50_. Result of the day has highest revenue (2022-09-03)._ .......................................................................... 40

Figure 51

. Query to find out the day has lowest revenue. .................................................................................... 40

Figure 52_. Result of the day has lowest revenue (2022-10-03)._ ........................................................................... 40

Figure 53_. Query to find out the loyal customers._ ................................................................................................ 41

Figure 54_. Result of finding out the loyal customers._

Figure 55_. ERD of pharmacy management system._ .............................................................................................. 46

Figure 56_. User Doc 1._ .......................................................................................................................................... 48

Figure 57_. User Doc 2._ .......................................................................................................................................... 50

Figure 58_. User Doc 3._ .......................................................................................................................................... 51

Figure 59_. User Doc 4._

Figure 60_. User Doc 5._ .......................................................................................................................................... 55

Figure 61_. User Doc 6._ .......................................................................................................................................... 56

Figure 1. The main interface of the system.

 Interface when user clicks View button. Items related to information of provider, customer, drug, order and order detail will

be displayed, users can click on the option to view information.

Figure 2. Menu of view option.

 When the user selects View Provider List, the interface will appear as follows.

Figure 4. View Customer list.

 When the user selects View Drug List, the interface will appear as follows.

Figure 5. View Drug list.

 When the user selects View Order List, the interface will appear as follows.

Figure 7. View Order detail list.

 The interface when the user clicks the Add button. Items related to more information of provider, drug, customers, and order

will be displayed, users can click on options to add necessary information.

Figure 8. Menu of Add option.

 The interface when the user clicks the Update button. Items related to additional information of provider, drug, customers,

and order will be displayed, users can click on options to edit necessary information.

 The interface when the user clicks the Statistic button. The statistics and other functions of the system will be displayed.

Users can choose View or Update for new updates.

Figure 10. Menu of Statistic option.

2. Queries to create database with results.

2.1 Queries to create database and tables.

 Before building the system, we need to create the database first.

Figure 11. Creating the database.

 Next, we need to create tables as mentioned in the design, including five tables: Provider, Drug, Customer, Order, OrderDetail.