Database Normalization Overview
- 18Unfamiliar
- 0Learning
- 0Familiar
- 0Mastered
What is the primary purpose of database normalization?
What is the primary purpose of database normalization?
18 questions
- 1
What is the primary purpose of database normalization?
- A
To reduce the number of tables in a database
- B
To ensure all tables have a composite primary key
- C
To avoid data redundancy and attain data integrity
- D
To increase data redundancy for faster queries
Correct answer
CTo avoid data redundancy and attain data integrity
Explanation
Normalization aims to avoid data redundancy and attain data integrity, as stated in the content.
- A
- 2
What type of anomaly occurs when a new agency cannot be inserted because it has no agent yet?
- A
Delete anomaly
- B
Read anomaly
- C
Insert anomaly
- D
Update anomaly
Correct answer
CInsert anomaly
Explanation
The inability to insert a new agency because the primary key (AgentId) would be null is an insert anomaly.
- A
- 3
Which anomaly arises when updating data in multiple rows leads to inconsistent state if some rows are not updated?
- A
Read anomaly
- B
Insert anomaly
- C
Update anomaly
- D
Delete anomaly
Correct answer
CUpdate anomaly
Explanation
Update anomaly occurs due to data redundancy; updating only some rows causes inconsistency.
- A
- 4
What happens if a delete operation removes an agent and also inadvertently removes the agency and client information?
- A
Update anomaly
- B
Insert anomaly
- C
Delete anomaly
- D
Referential integrity violation
Correct answer
CDelete anomaly
Explanation
Deleting an agent removes the associated agency and client data, which is a delete anomaly.
- A
- 5
Why is the denormalized FilmAgents table not in 1NF?
- A
It has a primary key that allows null values
- B
It violates the rule of atomicity for agent names
- C
It has data redundancy in agency name and location
- D
It contains a group of columns representing similar information (customer1, customer2, customer3)
Correct answer
DIt contains a group of columns representing similar information (customer1, customer2, customer3)
Explanation
1NF prohibits groups of columns representing similar information; here customer1, customer2, customer3 are such a group.
- A
- 6
According to 1NF, what must be true about each column value?
- A
It must be part of a composite key
- B
It must not contain any null values
- C
It must be unique across the table
- D
It must be atomic (single value)
Correct answer
DIt must be atomic (single value)
Explanation
1NF requires each column to be atomic, meaning a single value per column per row.
- A
- 7
Which of the following is NOT a requirement for a table to be in 1NF?
- A
All non-key columns must be dependent on the primary key
- B
Each column must contain atomic values
- C
There must be a primary key that uniquely identifies each row
- D
There should be no repeating groups of columns
Correct answer
AAll non-key columns must be dependent on the primary key
Explanation
The requirement that non-key columns depend on the primary key is part of 2NF, not 1NF.
- A
- 8
After achieving 1NF by splitting into AgentInfo and CustomerInfo tables, which anomaly is resolved?
- A
The inability to sort by customer name
- B
Delete anomaly for removing an agent with multiple customers
- C
Insert anomaly for a new agency without an agent
- D
Update anomaly for change in agency location
Correct answer
AThe inability to sort by customer name
Explanation
With a single customer name column, sorting becomes possible, resolving the read issue.
- A
- 9
What condition must a table satisfy to be in 2NF?
- A
Each table must have a single purpose
- B
All columns must be atomic and there must be a primary key
- C
All non-key columns must be fully functionally dependent on the primary key
- D
All non-key columns must be dependent on the primary key and no transitive dependencies
Correct answer
DAll non-key columns must be dependent on the primary key and no transitive dependencies
Explanation
2NF requires compliance with 1NF and that all non-key columns are dependent on the primary key (no partial dependencies for composite keys; here the rule is simplified to 'non-key columns should be dependent on primary key').
- A
- 10
In the AgentInfo table after 1NF, why is it not in 2NF?
- A
There is no foreign key to an agency table
- B
AgencyName, OfficeLocation, and OfficeContact describe the agency, not the agent
- C
The table has a composite primary key
- D
AgentName is not dependent on AgentId
Correct answer
BAgencyName, OfficeLocation, and OfficeContact describe the agency, not the agent
Explanation
Non-key columns like AgencyName describe the agency, not the agent (the entity identified by the primary key), violating the dependency rule of 2NF.
- A
- 11
How is the 2NF violation resolved in the AgentInfo table?
- A
By creating a join table between agents and customers
- B
By removing the AgencyId foreign key
- C
By splitting the table into AgentInfo and AgencyInfo, linking them via a foreign key
- D
By adding more columns to describe the agent
Correct answer
CBy splitting the table into AgentInfo and AgencyInfo, linking them via a foreign key
Explanation
To achieve 2NF, columns describing the agency are moved into a separate AgencyInfo table, with a foreign key (AgencyId) in AgentInfo.
- A
- 12
In the CustomerInfo table after 2NF, what transitive dependency exists?
- A
CustPinCode depends on CustCity, and CustCity depends on CId
- B
CustName depends on CId
- C
CustPinCode depends directly on CId
- D
CustCity depends on CId
Correct answer
ACustPinCode depends on CustCity, and CustCity depends on CId
Explanation
CustPinCode is transitively dependent on CId through CustCity, which violates 3NF.
- A
- 13
What is the rule for a table to be in 3NF?
- A
All non-key columns must be directly dependent on the primary key, with no transitive dependencies
- B
There must be a composite primary key
- C
All non-key columns must be dependent on the primary key, but transitive dependencies are allowed
- D
All columns must be atomic
Correct answer
AAll non-key columns must be directly dependent on the primary key, with no transitive dependencies
Explanation
3NF requires 2NF and that non-key columns are non-transitively (directly) dependent on the primary key.
- A
- 14
How is the CustomerInfo table made 3NF compliant?
- A
By combining CustCity and CustPinCode into one column
- B
By making CustPinCode the primary key
- C
By removing the CustPinCode column
- D
By creating a separate CustomerPinCodes table with CustPinCode and CustCity
Correct answer
DBy creating a separate CustomerPinCodes table with CustPinCode and CustCity
Explanation
To eliminate transitive dependency, CustPinCode and CustCity are moved to a new table where CustPinCode becomes a foreign key referencing the new table.
- A
- 15
What is the purpose of a join table (intersection table) in a normalized database?
- A
To store primary keys of two tables and represent a many-to-many relationship
- B
To ensure all tables have a single purpose
- C
To store non-key attributes that are dependent on multiple tables
- D
To combine multiple tables into one for faster queries
Correct answer
ATo store primary keys of two tables and represent a many-to-many relationship
Explanation
Join tables are used to represent many-to-many relationships by containing foreign keys from both tables.
- A
- 16
Which normal form is generally considered sufficient for a normalized database?
- A
BCNF
- B
2NF
- C
1NF
- D
3NF
Correct answer
D3NF
Explanation
The content states that if a database is in 3NF, it is sufficiently normalized.
- A
- 17
In the denormalized FilmAgents table, what is the primary key?
- A
AgentId
- B
AgencyName
- C
Customer1
- D
AgentName
Correct answer
AAgentId
Explanation
The content explicitly states that AgentId is the primary key in the denormalized table.
- A
- 18
What issue arises when trying to find the agency for a customer in the denormalized table?
- A
The data is stored in multiple tables
- B
Null values in customer columns cause errors
- C
The query must involve multiple OR conditions on several customer columns
- D
The primary key constraint prevents such a query
Correct answer
CThe query must involve multiple OR conditions on several customer columns
Explanation
To find the agency for a customer like Mr. Freeman, a query must check multiple customer columns (customer1, customer2, customer3) using OR conditions.
- A

Ask anything
We've read this whole study set, so questions about it get the best answers.