Normalization | 1 NF

First Normal Form (1NF)

It is the most basic level of database normalization. A table is in 1NF if it meets the following criteria:

Atomic Values: All the columns should contain atomic (indivisible) values, meaning each cell in the table …


This content originally appeared on DEV Community and was authored by Pranav Bakare

First Normal Form (1NF)

It is the most basic level of database normalization. A table is in 1NF if it meets the following criteria:

  • Atomic Values: All the columns should contain atomic (indivisible) values, meaning each cell in the table should hold a single value. No multiple values (like a list) in a single cell.
  • No Repeating Groups: There should be no repeating groups or arrays in the table. Each piece of data should be stored in a separate row and column.

Example of a Table Not in 1NF

Image description

OrderID CustomerName    PizzaSize   Toppings
001 Alice   Medium  Pepperoni, Mushrooms
002 Bob Large   Sausage, Olives
003 Charlie Small   Pepperoni

Issues:

The Toppings column contains multiple values (e.g., "Pepperoni, Mushrooms"), which violates 1NF because each cell should have only a single, atomic value.

Transforming to 1NF
To bring this table into 1NF, we need to ensure that each cell contains a single value:

Image description

Summary

A table is in 1NF when:

  • Each column contains atomic, indivisible values.
  • There are no repeating groups or arrays within rows.
  • 1NF helps ensure data consistency by breaking down data into the smallest meaningful units, making it easier to search, sort, and manage.


This content originally appeared on DEV Community and was authored by Pranav Bakare


Print Share Comment Cite Upload Translate Updates
APA

Pranav Bakare | Sciencx (2024-10-23T15:08:30+00:00) Normalization | 1 NF. Retrieved from https://www.scien.cx/2024/10/23/normalization-1-nf/

MLA
" » Normalization | 1 NF." Pranav Bakare | Sciencx - Wednesday October 23, 2024, https://www.scien.cx/2024/10/23/normalization-1-nf/
HARVARD
Pranav Bakare | Sciencx Wednesday October 23, 2024 » Normalization | 1 NF., viewed ,<https://www.scien.cx/2024/10/23/normalization-1-nf/>
VANCOUVER
Pranav Bakare | Sciencx - » Normalization | 1 NF. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2024/10/23/normalization-1-nf/
CHICAGO
" » Normalization | 1 NF." Pranav Bakare | Sciencx - Accessed . https://www.scien.cx/2024/10/23/normalization-1-nf/
IEEE
" » Normalization | 1 NF." Pranav Bakare | Sciencx [Online]. Available: https://www.scien.cx/2024/10/23/normalization-1-nf/. [Accessed: ]
rf:citation
» Normalization | 1 NF | Pranav Bakare | Sciencx | https://www.scien.cx/2024/10/23/normalization-1-nf/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.