0% found this document useful (0 votes)
6 views7 pages

2020 April s6 Database Practical Assignment

The document outlines a series of tasks related to database management systems, including creating databases, designing tables, entering records, generating queries, and creating reports for various scenarios such as car sales, estate agency, television stations, patient records, electoral commission, and employee payroll. Each question specifies the fields, data types, and requirements for forms and queries. The tasks emphasize practical application of database management skills in different contexts.

Uploaded by

isaac emmanuel
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views7 pages

2020 April s6 Database Practical Assignment

The document outlines a series of tasks related to database management systems, including creating databases, designing tables, entering records, generating queries, and creating reports for various scenarios such as car sales, estate agency, television stations, patient records, electoral commission, and employee payroll. Each question specifies the fields, data types, and requirements for forms and queries. The tasks emphasize practical application of database management skills in different contexts.

Uploaded by

isaac emmanuel
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

DATABASE MANAGEMENT SYSTEMS (DBMS)

QUESTION ONE:

(a) Load Database management software and create a database called HAMZAN COIN.
(01mk).

(b) Design a data table basing on the guidelines given in the table below and save the
table as CAR TABLE 1 (05mks).

Name of the field Properties of the field Field description


(i) Brand Name - Will contain only alphabetic Brand name of the
characters car
- Must not exceed 15
(ii) Manufacturer Name - Will contain only alphabetic Name of the
characters manufacturing
- Must not exceed 15 company
(iii) Car ID - A unique identification number. Unique number
- It comprises of only 5 characters assigned to the
car.
(iv) Body colour - The field should be set up to enable Colour of the body
database users choose from one of of the car.
these colours (Red, Army green,
Silver grey, White and Blue)
(v) 4-wheel drive - This field will have Boolean data Whether the car is
entries, a 4-wheel drive or
- Yes for those which are 4-wheel not
drive cars and No for those that are
not
(vi) Date out -The field will have entries in form The date when the
of dates. car left the depot
(vii)Customer -Will contain only alphabetical Name of the
characters. customer who
- Must not exceed 25. bought the car.
(c) (i) Create a Form for the above table showing all the fields. (03mks).

(ii) Include a form header of 2 lines (one below the other) reading as follows.

Line 1: HAMZAN CAR DEPOT LINE 2: Car Details form

(01mk)

(d) Enter the records below using the form which you created in (c) above.
(04mks)

1
Brand Manufacture Car ID Body 4-wheel Date Out Client
name r name Colour drive name

NADIA TOYOTA HZ010 WHITE YES 03/06/2010 KHAN


SHREE

DATSUN NISSAN HZ002 BLUE NO 06/04/2011 ODONG


TOM

PATROL NISSANI HZ013 SILVER YES 04/06/2012 GEERA


GREY TITIANA

HILUX TOYOTA HZ001 ARMY NO 01/04/2010 MUGISHA


GREEN HOPE

HONDA HONDA HZ004 RED NO 05/08/2010 LEMA


SHEM

PRADO TOYOTA HZ011 ARMY YES 14/09/2011 DDUMBA


GREEN
PAUL

(e) (i) create a report for the table and save it as TABLE 1 REPORT.

(ii) Group the records according to manufacturer name. (2mks)

(f) Include a report footer of your name and personal number (1mk)

(g) Create a Query showing all fields for the those cars manufactured by
TOYOTA and they are 4-wheel drive cars and save it as Toyota cars
(2mks)

(h) Print your work (01mk)

2
QUESTION TWO:

As a student of ICT you have been appointed as a Database Assistant and assigned the
following:

(a) Create a Database called Estate Agency in a single table using appropriate data types.
(b) Create a table in design view and name it Estate.

Field Name Field Type Field size


REF Reference number (04)
ESTATE AGENT Agent (15)
AREA Area of Location (15)
NO. OF BED ROOMS No. of Bedrooms (02)
TYPE Type of house (08)
GARDEN Type of Garden (06)
VALUE Cost of the house (UShs.) (15) no decimals

Ref Estate Agent Area No. of Type Garden Value


Bedrooms (Shs.)
1001 GA Property Kololo 3 Semi Large 53,000,000
1002 GA property Kyambogo 3 Detached Small 76,000,000
1003 Trust property Ntinda 4 Detached Large 145,000,000
1004 Trust Property Ntinda 2 Terraced Small 52,000,000
1005 Mazima Kireka 2 Flat None 39,000,000
1006 Watsons Bukoto 4 Semi Medium 65,000,000
1007 Watsons Kololo 2 Terraced Small 54,000,000
1008 Watsons Bukoto 3 Semi Medium 91,000,000
1009 Hozzana Naalya 2 Flat None 26,000,000
1010 Hozzana Kyambogo 3 Detached Medium 76,000,000
1011 Landmasters Ntinda 3 Semi Large 79,000,000
1012 Landmasters Kololo 3 Detached Medium 62,000,000

Required:
(i) In the Estate table, Set Ref as a Primary Key
(ii) Design a Data Entry Form based on the Estate Table and name it Estates
Data Entry Form
(iii) Using the Data Entry form created, enter the records in the ruled table above.
(iv) Create a Query to filter out all houses with small gardens, name it Small
Query.
(v) Create another query to filter out houses costing above 70M and name it
High Cost Houses
(vi) Create a report grouped by Area. Name it Estate Report.

3
QUESTION THREE:

(a) A survey made on Uganda’s social media has revealed that Uganda has a

a number of Local TV Stations with quite a number of viewers basing on the


programmes people like on these Stations. Create a Database under your personal
folder and name it Television.

(b) Design a table with the following information and set Station No. as the

Primary Key. Name the table Station.

Field Name Field Type Field Size

Station No. Auto number (3)

Programme Name Text (30)

Station Name Text (15)

Decoder Type Text (10)

Key Character Text (15)

Number of viewers Number Long Integer

Statio Programme Name Station Decoder Key No. of


n No. Name Type Character Viewers
S01 Badhe Achee Bukedde Star Times Priyah 8,000,000
S02 Deception NTV DSTV Monica 3,000,000
S03 The Favourite UBC Zuku TV Florence 2,000,000
S04 Don’t Mess with an NTV Star Times Maria 13,000,000
Angel Dehesus
S05 Choti Bakhu Bukedde DSTV Radika 13,000,000
S06 The Gardener’s UBC Zuku TV Pedro 7,000,000
Daughter
S07 Catalina & Sebastian WBS Star Times Sebastian 9,000,000
S08 Woman of my Life WBS DSTV Babarita 15,000,000
S09 Cuado Seas Mia UBC Zuku TV Paloma 13,000,000
S10 Second Chance NTV DSTV Salvador 20,000,000
S11 Legacy SPARK TV Star Times Natasha 12,000,000
S12 I will never say SPARK TV DSTV Waldo 10,000,000
Goodbye

(c) Use a form to populate the table and name the Form Stars.
(d) Design a query called Decoder to show stations viewed on Star Times.
(e) Create a query that shows programmes on UBC Station whose viewers are less than
10,000,000. Save the query as Viewers.
4
(f) Create a query to display programmes shown on NTV and Bukedde only. Name it TV.
(g) Generate a report using fields; Programme Name, Key Character and Decoder Type and
name it Station Report.
(h) Generate another report from the Station Table with all fields with grouping Levels based
on Station Name and name it Final Report.

QUESTION FOUR

The Table below shows the medical records of a certain clinic.

PID F Name District DoB Diagnosis Treat Fee


P01 Omondi Busia 03/02/66 Malaria 10,000
P04 Katiba Kampala 06/09/77 Typhoid 100,000
P05 Waiswa Busia 03/05/81 Tuberculosis 20,000
P06 Nambi Busia 02/08/89 Dysentery 120,000
P09 Lumu Kampala 04/05/90 Malaria 30,000
P11 Nafula Busia 05/11/89 Tuberculosis 20,000
P15 Waiswa Jinja 10/11/78 Malaria 60,000

(a) Create a database called patients (01mk)


(b) Design a table with appropriate data types in design view called Patients (04mks)
(c) Enter the given data in the table (02mks)
(d) Create a Query to display all details of patients who come from either Jinja or Busia.
Save it as Eastern Patients. (02mks)
(e) Create a Query to display all details of the patients who were not diagnosed with
malaria. Save it as No malaria. (02mks)
(f) If the Government pays 40% of the treat fee for all the patients, create a Query to
calculate discounted fee. Put only Fname, DoB, Diagnosis and Discounted fee
(03mks)
(g) Create a Report to display the information in the discounted fee query (3mks)

(h) Create a form from the discounted fee query showing all details and save it as
Patients Form. (02mks).

5
QUESTION FIVE

Your country is about to hold a referendum and the electoral Commission is looking for a
good database administrator. You have contacted to design and test your database with the
following records.

Voter Name Sex Date of Birth Constituency Salary

U001 Mafabi M 19-Nov-80 Katikamu North 560,000/=

U002 Mufulusi M 02-Apr-72 Kyegwgwa 760,000/=

U003 Kikami M 13-Jul-84 Masaka Central 990,000/=

U004 Fulasi F 01-Jun-69 Kampala Central 450,000/=

U005 Pikipiki M 11-Dec-81 Mbale East 390,000/=

U006 Serica F 12-Jan-79 Katikamu South 685,000/=

U007 Bada M 15-Feb-60 Wobulenzi 845,000/=

(a) Create a database and name it Electoral commission (01mk)


(b) Create a table above in design view and name it EC Table (03mks)
(c) Create a simple form and use it to enter the records shown in the above table
Use it to calculate the PAYE which is deducted from salary at a rate of 5%, name it
EC FORM. (04mks)

(d) Create a query displaying all fields. Use it to calculate the net Pay. Name it Net Pay.
(04mks)
(e) Create another query displaying only female Voters, name it females only. (2mks)

(f) Create a query for all male voters born before 1980. Name it Aged Males. (3mks)

(g) Create a report displaying all fields from the table above. Name it all voters. (2mks)

Save your work in a folder of yours names on the desktop.

6
QUESTION SIX

The table below represents SD employee Payroll. Study it and answer the questions that
follow.

ID EMPLOYEE BASIC
SEX AGE DEPARTMENT ALLOWANCES
NUMBER NAME SALARY

ASIIMWE
U12 F 52 COMPUTER 300000 20000
RUTH

TUGUME
U13 M 41 HISTORY 620000 32000
LEONARD

TUSHABE
U14 M 43 CONOMICS 320000 50000
ROBERT

NAMBI
U15 F 36 MATHS 450000 62000
TRACE

(a) Use a database Management software to create a database for SD Employees. Save it
as SD database. (01mk)

(b) Design a table and enter the given data. Save it as Employee Table (08mks)

(c) Use a query to filter out all female employees with their details. Save it Female
Query. (03mks)

(d) (i) Generate a report from the employee table and save it as Employee Report.
(02mks)
(ii) Add a header to the Report as SD EMPLOYEE PAYROLL and footer as
your name and personal number. (02mks)

(c) Use a Query to filter out employees who are between 40 and 50 years of age.
Save it as Aged. (03mk)

(f) Save and print all your work (01mk)

You might also like