这是数据库规范化中前 3 个范式的正确解释吗?
我试图在这篇博文中巩固我学到的关于标准化的所有知识 http://geekyisawesome.blogspot.com/2011 /03/database-normalization-1-2-3-nf.html 但我需要确保我正确理解了一切。你能通知我任何错误吗?
谢谢
I tried to consolidate everything I learned about normalization in this blog post
http://geekyisawesome.blogspot.com/2011/03/database-normalization-1-2-3-nf.html
but I need to make sure that I understood everything correctly. Could you notify me of any mistakes?
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
标准化并不意味着“用 ID 号替换值”。
规范化也不涉及诸如弱实体、桥接表或连接表之类的术语。
Normalization doesn't mean "replace values with ID numbers".
Normalization also doesn't involve terms like weak entity, bridge table, or junction table.
我不会说有任何错误。这些例子是合理的。我喜欢你展示了几种不同的 1NF 方法。
我想说这篇文章有点令人困惑。也许您可能会考虑对每个 NF 进行准确的说明,并简要描述 1NF 和 2NF 的主要异常情况。这样,当您查看示例关系时,会更清楚问题是什么以及为什么下一个 NF 是一种解决方案,而不仅仅是另一种实现方式。我发现从一个 NF 到下一个 NF 的转换并不是很清晰。新手会从每个 NF 之间更清晰的区别中受益更多,因为正如您在介绍中指出的那样,一开始很难保持头脑清醒。
我喜欢用古老的谚语来概括 3NF:“关键,整个关键,除了关键之外什么都没有,所以帮助我科德。”这非常简洁,突出了 3NF 关系的所有重要属性。每个属性必须依赖于键 (1NF) 和整个键 (2NF),并且仅依赖于键 (3NF)。这对于解释标准化毫无用处,但是一旦你学会了它,这是记住它的好方法。
I wouldn't say there are any mistakes. The examples are sound. I like the fact that you showed a couple of different ways of doing 1NF.
I would say that the post is a little bit confusing. Perhaps you might consider laying out a precise statement of what each NF is as you get to it and include a short description of what the attending anomalies are for 1NF and 2NF. That way, when you go through your sample relations, it will be clearer what the problems are and why the next NF is a solution rather than just another way of doing it. I found the transitions from one NF to the next weren't crystal clear. A neophyte would benefit more from clearer distinctions between each NF, since it can be hard to keep straight in your head at first, as you pointed out in your introduction.
I like how 3NF can be summed up in the old addage: "The key, the whole key, and nothing but the key, so help me Codd." This is very succinct and highlights all of the important attributes of a relation in 3NF. Each attribute must depend on the key (1NF) the whole key (2NF) and nothing but the key (3NF). This is useless for explaining normalization but it's a great way to remember it once you've learned it.