Help with normalization
-
Hi all, I have a project that I'm going to do.There's a table that has to be normalized.I've tried the normalization roughly.But i need your solution just to check mine with yours.Here's the table with sample data. I hhave taken Pay Item as a primary key:
Pay Item Description Bridge Type Span Unit Quantity
81.02(a)-I Soft materials-0-2m Slab 6 m3 726.092
81.02(a)-I Soft materials-0.2m Slab 8 m3 182.442
81.02(a)-I Soft materials-0.2m Slab 10 m3 255.36
81.02(a)-I Soft materials-0.2m T-Girder 12 m3 726.092
81.02(a)-I Soft materials-0.2m T-Girder 14 m3 329.864
81.02(a)-ii Soft materials Slab 6 m3 123.456
81.02(a)-ii Soft materials Slab 8 m3 240.762
81.02(a)-ii Soft materials T-Girder 12 m3 556.762
81.02(a)-ii Soft materials T-Girder 14 m3 192.56 -
Hi all, I have a project that I'm going to do.There's a table that has to be normalized.I've tried the normalization roughly.But i need your solution just to check mine with yours.Here's the table with sample data. I hhave taken Pay Item as a primary key:
Pay Item Description Bridge Type Span Unit Quantity
81.02(a)-I Soft materials-0-2m Slab 6 m3 726.092
81.02(a)-I Soft materials-0.2m Slab 8 m3 182.442
81.02(a)-I Soft materials-0.2m Slab 10 m3 255.36
81.02(a)-I Soft materials-0.2m T-Girder 12 m3 726.092
81.02(a)-I Soft materials-0.2m T-Girder 14 m3 329.864
81.02(a)-ii Soft materials Slab 6 m3 123.456
81.02(a)-ii Soft materials Slab 8 m3 240.762
81.02(a)-ii Soft materials T-Girder 12 m3 556.762
81.02(a)-ii Soft materials T-Girder 14 m3 192.56ah ... no - why dont you post what your table defs etc are - give it your best shot - else for all we know we could be doing your homework - and we dont do homework
-
Hi all, I have a project that I'm going to do.There's a table that has to be normalized.I've tried the normalization roughly.But i need your solution just to check mine with yours.Here's the table with sample data. I hhave taken Pay Item as a primary key:
Pay Item Description Bridge Type Span Unit Quantity
81.02(a)-I Soft materials-0-2m Slab 6 m3 726.092
81.02(a)-I Soft materials-0.2m Slab 8 m3 182.442
81.02(a)-I Soft materials-0.2m Slab 10 m3 255.36
81.02(a)-I Soft materials-0.2m T-Girder 12 m3 726.092
81.02(a)-I Soft materials-0.2m T-Girder 14 m3 329.864
81.02(a)-ii Soft materials Slab 6 m3 123.456
81.02(a)-ii Soft materials Slab 8 m3 240.762
81.02(a)-ii Soft materials T-Girder 12 m3 556.762
81.02(a)-ii Soft materials T-Girder 14 m3 192.56 -
Hi all, I have a project that I'm going to do.There's a table that has to be normalized.I've tried the normalization roughly.But i need your solution just to check mine with yours.Here's the table with sample data. I hhave taken Pay Item as a primary key:
Pay Item Description Bridge Type Span Unit Quantity
81.02(a)-I Soft materials-0-2m Slab 6 m3 726.092
81.02(a)-I Soft materials-0.2m Slab 8 m3 182.442
81.02(a)-I Soft materials-0.2m Slab 10 m3 255.36
81.02(a)-I Soft materials-0.2m T-Girder 12 m3 726.092
81.02(a)-I Soft materials-0.2m T-Girder 14 m3 329.864
81.02(a)-ii Soft materials Slab 6 m3 123.456
81.02(a)-ii Soft materials Slab 8 m3 240.762
81.02(a)-ii Soft materials T-Girder 12 m3 556.762
81.02(a)-ii Soft materials T-Girder 14 m3 192.56Pat Item, Bridge Typeand Unit should be split out as dimension tables.
Never underestimate the power of human stupidity RAH
-
-
ah ... no - why dont you post what your table defs etc are - give it your best shot - else for all we know we could be doing your homework - and we dont do homework
-
Ah, the old "I've solved it, but I'm not going to show you; I want to see your solution first so I can check" line. Which translates as, "I haven't solved it; I want you to solve it for me".
"These people looked deep within my soul and assigned me a number based on the order in which I joined." - Homer
-
Ah, the old "I've solved it, but I'm not going to show you; I want to see your solution first so I can check" line. Which translates as, "I haven't solved it; I want you to solve it for me".
"These people looked deep within my soul and assigned me a number based on the order in which I joined." - Homer
-
Let me show you my trial: First I put (PayItem,Description and unit)on a single table, Second (BridgeType,Span,quantity)on another table payitem as a foreign key. Now bridge type and span are making the redundancy problem,what should i do now?
Nebilo wrote:
First I put (PayItem,Description and unit)on a single table,
Why? Normalization consists of a set of rules that one can apply, one after the other. As is, the table is in 0NF. A "normalized" model is usually in BCNF (3NF+). That means that one verifies the rules for each level. If you follow the rules (!) we'd get exactly the same model.
Nebilo wrote:
what should i do now?
Start at the wikipedia, and see how you can turn your pile of data into 1NF.
Bastard Programmer from Hell :suss: If you can't read my code, try converting it here[^]