normalization

Questions about the MySQL, PostgreSQL, and most other databases, as well as using it with PHP can be asked here.

Moderator: General Moderators

Post Reply
User avatar
wvoyance
Forum Contributor
Posts: 135
Joined: Tue Apr 17, 2012 8:24 pm

normalization

Post by wvoyance »

To my understanding, the 1NF-6NF are only guidelines.
One has to inspect by eye.
Is there any program or algorithm that can do all the normalization for the DB I designed?

is there a mathematical procedure that I can crank, like to Fourier transform, to get a normalized DB?
Afterall, DB is only some set in mathematics.
User avatar
califdon
Jack of Zircons
Posts: 4484
Joined: Thu Nov 09, 2006 8:30 pm
Location: California, USA

Re: normalization

Post by califdon »

I would argue that a normalized database is a mathematical set, but until it is normalized, it is not a describable set. I have been in the field of database education for over 20 years and I know of no programmatic way to normalize a database. This is because everything depends on understanding the semantics of the data model. You have to know that a particular attribute is or is not dependent on another.

Guidelines, yes -- I know of no one who tries to normalize to even 5NF. But if you don't normalize to at least 3NF, don't expect SQL to consistently extract the data you may need. This was all studied exhaustively by Dr. E. F. Codd and others at IBM in the late 1960's, and although it's always possible that someone may improve on the concepts, it is widely accepted as the best way to structure a relational database, and the basis for the logic underlying SQL. Of course, there are other kinds of databases, such as trees and objects, but for a relational database, I urge you not to waste your time trying to think of shortcuts.
User avatar
wvoyance
Forum Contributor
Posts: 135
Joined: Tue Apr 17, 2012 8:24 pm

Re: normalization

Post by wvoyance »

califdon wrote:I would argue that a normalized database is a mathematical set, but until it is normalized, it is not a describable set. I have been in the field of database education for over 20 years and I know of no programmatic way to normalize a database. This is because everything depends on understanding the semantics of the data model. You have to know that a particular attribute is or is not dependent on another.

Guidelines, yes -- I know of no one who tries to normalize to even 5NF. But if you don't normalize to at least 3NF, don't expect SQL to consistently extract the data you may need. This was all studied exhaustively by Dr. E. F. Codd and others at IBM in the late 1960's, and although it's always possible that someone may improve on the concepts, it is widely accepted as the best way to structure a relational database, and the basis for the logic underlying SQL. Of course, there are other kinds of databases, such as trees and objects, but for a relational database, I urge you not to waste your time trying to think of shortcuts.
Are you saying a DB not reach 3NF surely will have problem?
(I just want to clarify this problem. I have only 2 months experience in DB design.)

:wink:
User avatar
califdon
Jack of Zircons
Posts: 4484
Joined: Thu Nov 09, 2006 8:30 pm
Location: California, USA

Re: normalization

Post by califdon »

wvoyance wrote:Are you saying a DB not reach 3NF surely will have problem?
(I just want to clarify this problem. I have only 2 months experience in DB design.)
One can never say "surely will", but if a relational database doesn't meet the requirements of 3NF, you may be unable to form certain kinds of SQL joins and be limited to what kind of data you will be able to retrieve. Keep in mind that the SQL logic was developed based on the assumption that the data is normalized.
User avatar
wvoyance
Forum Contributor
Posts: 135
Joined: Tue Apr 17, 2012 8:24 pm

Re: normalization

Post by wvoyance »

califdon wrote:
wvoyance wrote:Are you saying a DB not reach 3NF surely will have problem?
(I just want to clarify this problem. I have only 2 months experience in DB design.)
One can never say "surely will", but if a relational database doesn't meet the requirements of 3NF, you may be unable to form certain kinds of SQL joins and be limited to what kind of data you will be able to retrieve. Keep in mind that the SQL logic was developed based on the assumption that the data is normalized.
Can you give some simple example? That will be interesting.
Post Reply