0% found this document useful (0 votes)
16 views

Database Systems Design Marking Guide

Database normalization is a process that organizes data in a relational database to eliminate redundancy and improve integrity. It involves breaking large tables into smaller related tables to reduce duplication. Normal forms include 1NF, 2NF, 3NF and BCNF. Anomalies like insertion and update anomalies can be fixed through normalization.

Uploaded by

stephen
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
16 views

Database Systems Design Marking Guide

Database normalization is a process that organizes data in a relational database to eliminate redundancy and improve integrity. It involves breaking large tables into smaller related tables to reduce duplication. Normal forms include 1NF, 2NF, 3NF and BCNF. Anomalies like insertion and update anomalies can be fixed through normalization.

Uploaded by

stephen
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

"Question six

a)What is database normalization? (02 marks)

b)Use example to discuss the different forms of Normalization. (16 marks)

c)Give two examples of database Anomalies.

ChatGPT

a) Database normalization is a process in database design that organizes data in a relational database to
eliminate data redundancy and improve data integrity. It involves breaking down large tables into
smaller related tables, reducing data duplication, and establishing relationships between them. This is
typically done through a series of rules known as normal forms.

b) Database normalization has several normal forms, with the most common ones being 1NF (First
Normal Form), 2NF (Second Normal Form), 3NF (Third Normal Form), and BCNF (Boyce-Codd Normal
Form). Let's discuss these forms with an example:

Imagine a database for a library. A table for books might initially have attributes like (BookID, Title,
Author, Publisher, and ISBN).

1NF: To achieve 1NF, make sure each attribute contains only atomic (indivisible) values. In this case, split
the Author into first name and last name.

2NF: Now, ensure that non-key attributes depend on the entire primary key. Create a new table for
Authors with AuthorID as the primary key and link it to the Books table with AuthorID.

3NF: Remove transitive dependencies. Create a Publishers table with PublisherID as the primary key and
link it to the Books table via PublisherID.

BCNF: Ensure that for every non-trivial functional dependency, the left-hand side is a superkey. In this
case, you might need to further refine the structure based on specific dependencies.
c) Two examples of database anomalies are:

Insertion Anomaly: This occurs when you can't insert a piece of data into the database without also
inserting unrelated data. In the library example, if you can't add a new book without specifying an
author (even if the author is not yet associated with any other book), it's an insertion anomaly.

Update Anomaly: This happens when updating data in the database leads to inconsistencies. For
instance, if you update an author's name in one book entry but forget to update it in other books by the
same author, it creates inconsistency.

These anomalies can be eliminated or reduced through proper database normalization.

Question seven

a)Differentiate between the terms database and database management systems.(05 marks)

b)Create the following table and add the stated data into it: SALES DATA (05 marks)

SALESidSDdateFOODidamountEmployee

name

S00131/5/202313000Ronald

S00231/5/202325000Marvin

S00330/4/202316000Kate

S00430/4/2023210000Jane

c)Create queries andthe associated output to display: (10marks)


i.A list of sales data items (salesid, amount) sold on 31/5/2023

ii.List of employees (employeename, foodid) who sold food item with id = 2

iii.A list of employees and their total sales

END

ChatGPT

a) Database refers to a structured collection of data that is stored and

network error

There was an error generati"

https://chat.openai.com/c/4fd8d9bf-1499-46e4-8471-b96acb35a415#:~:text=Question%20six%0Aa,an
%20error%20generating

You might also like