How do you teach database normalization?

前端 未结 9 1481
孤街浪徒
孤街浪徒 2020-12-06 13:58

What are your steps and guidelines for database normalization? If given a bunch of people with good computer and logic skills, how do you explain to them how to normalize a

9条回答
  •  天命终不由人
    2020-12-06 14:23

    One of the first lessons--and one of the most important--is that the normal forms apply to individual tables, not to databases. It makes sense to say, "The table 'wibble' is in BCNF", but it doesn't make sense to say "This database is in 3NF."

    I see two big problems very frequently in dealing with database developers.

    1. Trying to normalize a table based on column names rather than on representative sample data.
    2. Not understanding functional dependencies.

    Those two are interrelated, in that functional dependencies are defined in terms of values, not in terms of column names.

提交回复
热议问题