IniziaInizia gratis

Applying 2NF

Your productqualityrating entity is a rich dataset that captures the essence of chocolate bars reviewed over various years. You noticed that the company_location attribute depends on the manufacturer attribute. The company_location values repeat every time they are together with the manufacturer attribute, which violates the second normal form's rule against partial dependencies.

By separating this data into a dedicated manufacturers entity, you can remove redundancies and prepare our data model for more efficient operations. This step is crucial in maintaining data integrity and allows scalable business intelligence solutions.

Your task is to normalize this data to align with 2NF principles, ensuring that each non-key attribute entirely depends on the primary key.

Questo esercizio fa parte del corso

Introduction to Data Modeling in Snowflake

Visualizza il corso

Esercizio pratico interattivo

Prova a risolvere questo esercizio completando il codice di esempio.

-- Add new entity
___ (
  	-- Assign unique identifier
  	___ NUMBER(10,0) PRIMARY KEY,
  	--Add other attributes
  	___ VARCHAR(255),
  	___ VARCHAR(255)
);
Modifica ed esegui il codice