Normalization:-
Normalization is the process of organizing data in a database. It includes
creating tables and establishing relationships between those tables
according to rules designed both to protect the data and to make the
database more flexible by eliminating redundancy and inconsistent
dependency.
Redundant data wastes disk space and creates maintenance problems. If
data that exists in more than one place must be changed, the data must
be changed in exactly the same way in all locations. A customer address
change is easier to implement if that data is stored only in the Customers
table and nowhere else in the database.
1. First normal form
Eliminate repeating groups in individual tables.
Create a separate table for each set of related data.
Identify each set of related data with a primary key.
2. Second normal form
Create separate tables for sets of values that apply to multiple
records.
Relate these tables with a foreign key.
3. Third normal form
Eliminate fields that don't depend on the key.
E-R diagram:
Train passenger
have
Train_id Ticket_no
Train_id Train_name
Des_location Passenger_id