Exercise 58

SQL Normalization

In the previous exercise, we explored SQL basics using the European Central Bank’s historic Euro data set. In this exercise I’m going to teach you about data modeling by reshaping this data into multiple tables to “normalize” it.

What Is Normalization?

Normalization is about reducing redundancy in your data set. You see some form of redundancy, move it into a separate table, and then link the two tables via an id column. It gets far more complex and theoretical, but this is the general idea. Doing this has a few advantages:

  1. It reduces the size of your data, and reduced size generally improves performance (but not always).

  2. It helps you understand the structure of the data possibly giving you better insights into ...

Get Learn Python the Hard Way: A Deceptively Simple Introduction to the Terrifyingly Beautiful World of Computers and Data Science, 5th Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.