数据标准化不能达到3nf

时间:2015-08-06 12:01:36

标签: mysql database database-design normalization database-normalization

您好我正在尝试将我的数据从一个场景规范化到3NF。有这么远,但不确定它是否正确,因为我不知道如何从2nf到3nf ...任何帮助将不胜感激。

UNF

* Property ID
* Weekly Rate
* Property Type (repeating)
* Location (Repeating)
* owner (repeating)
* owner address (repeating)
* no of rooms (repeating)
* kitchen(repeating)

1NF

* Property ID (PK)
* Weekly Rate

----------


* Owner (PK)
* Property ID (FK)
* Location
* Property Type
* Owner Address
* No Of Rooms
* Kitchen

2NF

* Property ID (PK)
* Weekly Rate


----------


* Owner (PK)
* Property ID (FK)
* Owner Address


----------


* Property ID (PK)
* Location
* Property Type
* No of Rooms
* Kitchen

这是因为我还不确定如何将它变成3nf并且不确定两个表中的属性ID是否为(PK)是否正确?

1 个答案:

答案 0 :(得分:2)

3NF = 2NF +没有依赖于另一个非关键属性的非关键属性

Property
-------------------
Property ID
Owner ID
Location (unknown? Beach?)
Address
Weekly Rate
Property Type
No of Rooms
Kitchen (Yay, Nay)



Owner
-------------------
Owner ID
Address