Top Banner
A337 - Reed Smith 1 Structure What is a database? Table of information • Rows are referred to as records • Columns are referred to as fields • Record identifier is referred to as a record key Example using an inventory file
36

Structure

Jan 12, 2016

Download

Documents

Structure. What is a database? Table of information Rows are referred to as records Columns are referred to as fields Record identifier is referred to as a record key Example using an inventory file. Types of databases. Relational Most common - PowerPoint PPT Presentation
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Structure

A337 - Reed Smith 1

Structure

• What is a database?– Table of information

• Rows are referred to as records• Columns are referred to as fields• Record identifier is referred to as a record key

• Example using an inventory file

Page 2: Structure

A337 - Reed Smith 2

Types of databases• Relational

– Most common• Separate files that are related by one or more common

pieces of information• Access programs are what combine the information

• Hierarchical– Some files belong to other files.– UPC codes

• Network• Object-Oriented

Page 3: Structure

A337 - Reed Smith 3

Relational Databases

• Relations– How two files can be combined together– When we normalize files, we put information

in smaller matrices that are more efficient. They are combined with relations

• Example

Page 4: Structure

A337 - Reed Smith 4

Relations

Code Type Description Cost Price Units Quantity ROP Vendor Value on Hand

Inventory Master File

Vendor Vendor Address CityStZip Terms Amount Owed

Vendor File

Page 5: Structure

A337 - Reed Smith 5

Relations

Code Type Description Cost Price Units Quantity ROP Vendor Value on Hand

Inventory Master File

Txn_No. Date Code Qty_Sold

Sales Txn File

Page 6: Structure

A337 - Reed Smith 6

Relations

Page 7: Structure

A337 - Reed Smith 7

SQL (Structured Query Language)

• The basic underlying language behind a DBMS is called a Structured Query Language and is abbreviated SQL.

• Typically, we do not actually USE the SQL in most database applications such as ACCESS. Rather we use a psuedo-code variation of it. ACCESS then translates the psuedo-code version to SQL.

Page 8: Structure

A337 - Reed Smith 8

Database structure

• Now, we will look at the structure of a database (a group of tables with fields and relations)

• Two approaches to the structure issue:– Empirical (you already know what data there will be -

you just want to organize it into tables)– Conceptual (you start with the question of “what

information should I have?”)

• First approach - NORMALIZATION

Page 9: Structure

A337 - Reed Smith 9

Normalization

• We have briefly discussed the importance of file structure.

• Now, we will formalize this discussion• A good resource for our discussion is

chapter 3 of the Perry/Schneider text.

Page 10: Structure

A337 - Reed Smith 10

Normalization• Why?

– Data structures need to:• Have a fixed structure• Minimize redundancy• Avoid insertion and deletion anomalies

• How?– Restructure information such that:

• Only flat (rectangular) files exist (1st normal form)• All items in each record depend upon (are identified by) the

primary record key (2nd normal form)• If one field depends upon another then the “other” must be

the primary record key (3rd normal form)

– Examples

Page 11: Structure

A337 - Reed Smith 11

Normalize the following table:

SALES_ORDERSSO_Number Item_Number Item_Name Qty_Ordered Cust_Code Cust_Name

1010 2010-0050 Formed Handlebar 2 WHEEL Wheelaway Cycle Center1000-1 20 in. Bicycle 5 WHEEL Wheelaway Cycle Center

1011 1002-1 24 in. Bicycle 5 ETC Bikes Et Cetera1001-1 26 in. Bicycle 10 ETC Bikes Et Cetera

1012 1003-1 20 in. Bicycle 5 WHEEL Wheelaway Cycle Center1001-1 26 in. Bicycle 10 WHEEL Wheelaway Cycle Center

1013 1001-1 26 in. Bicycle 50 IBS Inter. Bicycle Sales1014 1003-1 20 in. Bicycle 25 ETC Bikes Et Cetera1015 1003-1 20 in. Bicycle 25 WHEEL Wheelaway Cycle Center1016 3961-1041 Tire Tube, 26 in. 5 ETC Bikes Et Cetera

3965-1050 Spoke Reflector 50 ETC Bikes Et Cetera1003-1 20 in. Bicycle 5 ETC Bikes Et Cetera1000-1 20 in. Bicycle 4 ETC Bikes Et Cetera

Page 12: Structure

A337 - Reed Smith 12

What is wrong with this file?

• The dimensions of the file are not defined– How many columns does it have????

• There is a lot of data redundancy– This is a problem for a couple of reasons

Page 13: Structure

A337 - Reed Smith 13

What is normalization

• We will take the data in a file and redistribute it to other files.

• We then put the data back together with a series of relations.

• The primary tools will be:– Column choices– Primary key choices– Relations

Page 14: Structure

A337 - Reed Smith 14

Two ways to approach normalization

• Conceptual approach– By understanding the relationships and the nature of

all of the data columns, you can design the data structure so that the files are in the best possible “form”

• Empirical approach– Given a dataset, you can draw inferences about the

data based upon a “little” common sense and redundancies in the data

– We will (for this class) tend towards this approach

Page 15: Structure

A337 - Reed Smith 15

Consider the following table:

SALES_ORDERSSO_Number Item_Number Item_Name Qty_Ordered Cust_Code Cust_Name

1010 2010-0050 Formed Handlebar 2 WHEEL Wheelaway Cycle Center1000-1 20 in. Bicycle 5 WHEEL Wheelaway Cycle Center

1011 1002-1 24 in. Bicycle 5 ETC Bikes Et Cetera1001-1 26 in. Bicycle 10 ETC Bikes Et Cetera

1012 1003-1 20 in. Bicycle 5 WHEEL Wheelaway Cycle Center1001-1 26 in. Bicycle 10 WHEEL Wheelaway Cycle Center

1013 1001-1 26 in. Bicycle 50 IBS Inter. Bicycle Sales1014 1003-1 20 in. Bicycle 25 ETC Bikes Et Cetera1015 1003-1 20 in. Bicycle 25 WHEEL Wheelaway Cycle Center1016 3961-1041 Tire Tube, 26 in. 5 ETC Bikes Et Cetera

3965-1050 Spoke Reflector 50 ETC Bikes Et Cetera1003-1 20 in. Bicycle 5 ETC Bikes Et Cetera1000-1 20 in. Bicycle 4 ETC Bikes Et Cetera

Page 16: Structure

A337 - Reed Smith 16

First normal form

• First normal form means that the file has a rectangular structure.

• Anytime a column is “repeated” within a row (for any row), we must move that column data into a new row to eliminate the repeat.

• This means we will have to have a composite primary key (a primary key with more than one column)

Page 17: Structure

A337 - Reed Smith 17

• 1NF:

SALES_ORDERSSO_Number Item_Number Item_Name Qty_Ordered Cust_Code Cust_Name

1010 2010-0050 Formed Handlebar 2 WHEEL Wheelaway Cycle Center1010 1000-1 20 in. Bicycle 5 WHEEL Wheelaway Cycle Center1011 1002-1 24 in. Bicycle 5 ETC Bikes Et Cetera1011 1001-1 26 in. Bicycle 10 ETC Bikes Et Cetera1012 1003-1 20 in. Bicycle 5 WHEEL Wheelaway Cycle Center1012 1001-1 26 in. Bicycle 10 WHEEL Wheelaway Cycle Center1013 1001-1 26 in. Bicycle 50 IBS Inter. Bicycle Sales1014 1003-1 20 in. Bicycle 25 ETC Bikes Et Cetera1015 1003-1 20 in. Bicycle 25 WHEEL Wheelaway Cycle Center1016 3961-1041 Tire Tube, 26 in. 5 ETC Bikes Et Cetera1016 3965-1050 Spoke Reflector 50 ETC Bikes Et Cetera1016 1003-1 20 in. Bicycle 5 ETC Bikes Et Cetera1016 1000-1 20 in. Bicycle 4 ETC Bikes Et Cetera

Page 18: Structure

A337 - Reed Smith 18

So, now what is wrong?

• Every item name (as an example) refers to a unique item ID. – In other words, the sales order number is

not relevant in the determination of the item name

– Similarly, the customer code and customer name do not depend upon the Item ID, they only depend upon the sales order number.

• HOW DO WE KNOW THIS???

Page 19: Structure

A337 - Reed Smith 19

So, what do we do?

• We break this into (up to) three files.– The NON-KEY columns of one file will

depend upon BOTH columns of the primary key.

– The NON-KEY columns of the other file(s) will depend upon only one column of the file with a composite key.

Page 20: Structure

A337 - Reed Smith 20

• 2NF:

SALES_ORDER line item INVENTORYSO_Number Item_Number Qty_Ordered

1010 2010-0050 21010 1000-1 51011 1002-1 51011 1001-1 101012 1003-1 51012 1001-1 101013 1001-1 501014 1003-1 251015 1003-1 251016 3961-1041 51016 3965-1050 501016 1003-1 51016 1000-1 4

SALES_ORDERSSO_Number Cust_Code Cust_Name

1010 WHEEL Wheelaway Cycle Center1011 ETC Bikes Et Cetera1012 WHEEL Wheelaway Cycle Center1013 IBS Inter. Bicycle Sales1014 ETC Bikes Et Cetera1015 WHEEL Wheelaway Cycle Center1016 ETC Bikes Et Cetera

INVENTORY_ITEMSItem_Number Item_Name1000-1 20 in. Bicycle1001-1 26 in. Bicycle1002-1 24 in. Bicycle1003-1 20 in. Bicycle1003-1 20 in. Bicycle2010-0050 Formed Handlebar3961-1041 Tire Tube, 26 in.3965-1050 Spoke Reflector

Page 21: Structure

A337 - Reed Smith 21

Are we done, yet???

• No, but almost - one thing left• Notice that the third column of the Sales

Orders file has the Customer name and that depends upon the customer number.– The customer number is not the primary key to the

file

• Pull the customer number and customer name out and put them in a separate file with customer number as the primary key

• PUT EVERYTHING BACK TOGETHER WITH RELATIONS

Page 22: Structure

A337 - Reed Smith 22

• 3NF:

SALES_ORDER line item INVENTORYSO_Number Item_Number Qty_Ordered

1010 2010-0050 21010 1000-1 51011 1002-1 51011 1001-1 101012 1003-1 51012 1001-1 101013 1001-1 501014 1003-1 251015 1003-1 251016 3961-1041 51016 3965-1050 501016 1003-1 51016 1000-1 4

SALES_ORDERSSO_Number Cust_Code

1010 WHEEL1011 ETC1012 WHEEL1013 IBS1014 ETC1015 WHEEL1016 ETC

INVENTORY_ITEMSItem_Number Item_Name1000-1 20 in. Bicycle1001-1 26 in. Bicycle1002-1 24 in. Bicycle1003-1 20 in. Bicycle1003-1 20 in. Bicycle2010-0050 Formed Handlebar3961-1041 Tire Tube, 26 in.3965-1050 Spoke Reflector

CUSTOMERSCust_Code Cust_Name

ETC Bikes Et CeteraIBS Inter. Bicycle SalesWHEEL Wheelaway Cycle Center

Page 23: Structure

A337 - Reed Smith 23

PACKID TAGNUM COMPID INSTDATE SOFTCOST EMPNUM EMPNAME LOCATIONAC01 32808 M579 9/13/95 754.95 611 Dinh, Melissa AccountingDB32 32808 M579 12/13/95 380.00 611 Dinh, Melissa Accounting

37691 B121 6/15/95 380.00 124 Alvarez, Ramon SalesDB33 57772 C007 5/27/95 412.77 567 Feinstein, Betty Info SystemsWP08 37691 B121 6/15/95 227.50 124 Alvarez, Ramon Sales

57772 C007 5/27/95 170.24 567 Feinstein, Betty Info SystemsWP09 59836 B221 10/30/95 35.00 124 Alvarez, Ramon Home

77740 M579 5/27/95 35.00 567 Feinstein, Betty Home

SOFTWARE

Normalization Example 1

Page 24: Structure

A337 - Reed Smith 24

1st Normal Form

PACKID TAGNUM COMPID INSTDATE SOFTCOST EMPNUM EMPNAME LOCATIONAC01 32808 M579 9/13/95 754.95 611 Dinh, Melissa AccountingDB32 32808 M579 12/13/95 380.00 611 Dinh, Melissa AccountingDB32 37691 B121 6/15/95 380.00 124 Alvarez, Ramon SalesDB33 57772 C007 5/27/95 412.77 567 Feinstein, Betty Info SystemsWP08 37691 B121 6/15/95 227.50 124 Alvarez, Ramon SalesWP08 57772 C007 5/27/95 170.24 567 Feinstein, Betty Info SystemsWP09 59836 B221 10/30/95 35.00 124 Alvarez, Ramon HomeWP09 77740 M579 5/27/95 35.00 567 Feinstein, Betty Home

SOFTWARE

Primary Key

Page 25: Structure

A337 - Reed Smith 25

Normalization:2NF and 3NF

For normalizing tables, the “best” approach is to look at the data definitions in the data dictionary.

Short of that, you will have to infer data characteristics from looking at the data and assuming that it tells you everything that you need to know.

This is the approach that we will follow in this class - knowing that it is incomplete.

The important characteristic that will tell you about the data when approaching it this way is DUPLICATE data. Duplicates can tell you what data is related to what other data because if every duplicate in one column corresponds to a duplicate in another column, the inference can be drawn that the two columns are related.

Be careful - recall our discussion of functions - when going from 1NF (1st Normal Form) to 2NF. For this, it is only important to look if duplicates in a Potential Primary Key Column (what I jokingly referred to as PPKC) correspond with duplicates in some other column. It is not necessary that duplicates in that other column necessarily correspond to a duplicate in the PPKC. An example on the next page is COMPID M579. It appears twice for two different TAGNUMS. That is OK. It is only important that there are not two different COMPIDs for the same TAGNUM (you would have to look back to 1NF to find out).

Page 26: Structure

A337 - Reed Smith 26

2nd Normal Form

PACKID TAGNUM INSTDATE SOFTCOSTAC01 32808 9/13/95 754.95 DB32 32808 12/13/95 380.00 DB32 37691 6/15/95 380.00 DB33 57772 5/27/95 412.77 WP08 37691 6/15/95 227.50 WP08 57772 5/27/95 170.24 WP09 59836 10/30/95 35.00 WP09 77740 5/27/95 35.00

ID_TAG

CPTRTAGNUM COMPID EMPNUM EMPNAME LOCATION

32808 M579 611 Dinh, Melissa Accounting37691 B121 124 Alvarez, Ramon Sales57772 C007 567 Feinstein, Betty Info Systems59836 B221 124 Alvarez, Ramon Home77740 M579 567 Feinstein, Betty Home

To move to 2NF, look at duplicate value in ONE primary key column in 1NF and see if each duplicate in the primary key corresponds to a duplicate in another column. IF SO, those two columns can be pulled out into another table.

Note that there is no 2NF table with PACKID as the primary key. This is because none of the data depends ONLY on PACKID. In other words, knowing the PACKID does help you to identify the SOFTCOST or the INSTDATE

HINT: 2NF tables will have primary keys that are part or all of the primary keys for 1NF. NO new primary key columns will be added.

Page 27: Structure

A337 - Reed Smith 27

3rd Normal Form

PACKID TAGNUM INSTDATE SOFTCOSTAC01 32808 9/13/95 754.95 DB32 32808 12/13/95 380.00 DB32 37691 6/15/95 380.00 DB33 57772 5/27/95 412.77 WP08 37691 6/15/95 227.50 WP08 57772 5/27/95 170.24 WP09 59836 10/30/95 35.00 WP09 77740 5/27/95 35.00

ID_TAGTAGNOTAGNUM COMPID EMPNUM LOCATION

32808 M579 611 Accounting37691 B121 124 Sales57772 C007 567 Info Systems59836 B221 124 Home77740 M579 567 Home

EMPLOYEEEMPNUM EMPNAME

124 Alvarez, Ramon567 Feinstein, Betty611 Dinh, Melissa

For 3NF, look at duplicates in NON-KEY columns and see if there is another NON-KEY column that has corresponding duplicates in the same places. IF SO, then those two columns can be combined (with no repeating rows) into another table. The primary key of that table will need to be in the original table too.

HINT: For moving from 2NF to 3NF, new tables will have primary keys that ARE NOT a part of the primary key for a 2NF table (they will be new

Page 28: Structure

A337 - Reed Smith 28

Normalization Example 2

SSN LAST_NAME FIRST_NAME PHONE_NO LIC_PLATE_ST LIC_PLATE_NO TICKET_NO DATE CODE FINE123-34-5678 Curry Dorothy (916)358-4448 CA 123 MCD 10151 10/15/98 A 10$

10152 10/16/98 B 20$ 10121 11/12/98 B 20$

134-56-7783 Fong May (916)563-7865 CA 253 DAL 10231 10/23/98 C 50$ 12051 12/5/98 A 10$

PARKING TICKETS

Don’t be tricked!!! The first column of the data is not always the primary key of the 1NF table.

Page 29: Structure

A337 - Reed Smith 29

1st Normal Form

TICKET_NO SSN LAST_NAME FIRST_NAME PHONE_NO LIC_PLATE_ST LIC_PLATE_NO DATE CODE FINE10151 123-34-5678 Curry Dorothy (916)358-4448 CA 123 MCD 10/15/98 A 10$ 10152 123-34-5678 Curry Dorothy (916)358-4448 CA 123 MCD 10/16/98 B 20$ 10121 123-34-5678 Curry Dorothy (916)358-4448 CA 123 MCD 11/12/98 B 20$ 10231 134-56-7783 Fong May (916)563-7865 CA 253 DAL 10/23/98 C 50$ 12051 134-56-7783 Fong May (916)563-7865 CA 253 DAL 12/5/98 A 10$

Primary Key

PARKING TICKETS

If 1NF has only one column as the primary key (no composite key) then 1NF and 2NF are the SAME!!!!!

Page 30: Structure

A337 - Reed Smith 30

2nd Normal Form

TICKET_NO SSN LAST_NAME FIRST_NAME PHONE_NO LIC_PLATE_ST LIC_PLATE_NO DATE CODE FINE10151 123-34-5678 Curry Dorothy (916)358-4448 CA 123 MCD 10/15/98 A 10$ 10152 123-34-5678 Curry Dorothy (916)358-4448 CA 123 MCD 10/16/98 B 20$ 10121 123-34-5678 Curry Dorothy (916)358-4448 CA 123 MCD 11/12/98 B 20$ 10231 134-56-7783 Fong May (916)563-7865 CA 253 DAL 10/23/98 C 50$ 12051 134-56-7783 Fong May (916)563-7865 CA 253 DAL 12/5/98 A 10$

Primary Key

PARKING TICKETS

Page 31: Structure

A337 - Reed Smith 31

3rd Normal Form

TICKET_NO SSN DATE CODE10151 123-34-5678 10/15/98 A10152 123-34-5678 10/16/98 B10121 123-34-5678 11/12/98 B10231 134-56-7783 10/23/98 C12051 134-56-7783 12/5/98 A

PARKING TICKETS

REGISTRATIONSSN LAST_NAME FIRST_NAME PHONE_NO LIC_PLATE_ST LIC_PLATE_NO123-34-5678 Curry Dorothy (916)358-4448 CA 123 MCD134-56-7783 Fong May (916)563-7865 CA 253 DAL

FINESCODE FINE

A 10$ B 20$ C 50$

As we discussed in class, knowing the nature of the information, we can see that one person can have two cars and probably LIC_PLATE_NO should be the primary key for the REGISTRATION table and the foreign key for the PARKING_TICKETS table and that another table with LIC_PLATE_NO and LIC_PLATE_ST as a primary key and SSN as a foreign key should exist. See the next slide

Page 32: Structure

A337 - Reed Smith 32

3rd Normal Form

TICKET_NO LIC_PLATE_NO LIC_PLATE_ST DATE10151 123 MCD CA 10/15/9810152 123 MCD CA 10/16/9810121 123 MCD CA 11/12/9810231 253 DAL CA 10/23/9812051 253 DAL CA 12/5/98

PARKING TICKETS

REGISTRATIONLIC_PLATE_NO LIC_PLATE_ST SSN

123 MCD CA 123-34-5678253 DAL CA 134-56-7783

FINESCODE FINE

A 10$ B 20$ C 50$

INDIVIDUALSSSN LAST_NAME FIRST_NAME PHONE_NO123-34-5678 Curry Dorothy (916)358-4448134-56-7783 Fong May (916)563-7865

You could not havefigured this out byjust looking at the data!!!

You would not haveto do this on an EXAM!

Page 33: Structure

A337 - Reed Smith 33

Normalization ExerciseInvoiceID CustomerID CompanyName PhoneNumber Contact InventoryID Quantity UnitPrice

214123 30139Cavco Industries Inc. (602) 555-6141Golkin, David 1207 10 $8.401191 15 $4.501101 10 $8.101143 1 $6.30

214390 30174Thomas Nelson Inc. (615) 555-9079Harber, L. H. 1157 12 $9.301171 4 $7.401187 3 $22.001224 14 $15.201226 11 $12.90

214418 30174Thomas Nelson Inc. (615) 555-9079Harber, L. H. 1250 1 $11.601175 8 $11.701114 10 $9.50

214460 30139Cavco Industries Inc. (602) 555-6141Golkin, David 1141 9 $7.901136 3 $7.001143 1 $6.301149 20 $6.001207 3 $8.401104 16 $5.30

214480 30125Alamo Group Inc. (210) 555-1483Maul, Duane A. 1207 20 $8.401143 1 $6.301136 18 $7.001250 4 $11.60

Page 34: Structure

A337 - Reed Smith 34

1st Normal FormInvoiceID InventoryID CustomerID CompanyName PhoneNumber Contact Quantity UnitPrice

214123 1207 30139Cavco Industries Inc. (602) 555-6141Golkin, David 10 $8.40214123 1191 30139Cavco Industries Inc. (602) 555-6141Golkin, David 15 $4.50214123 1101 30139Cavco Industries Inc. (602) 555-6141Golkin, David 10 $8.10214123 1143 30139Cavco Industries Inc. (602) 555-6141Golkin, David 1 $6.30214390 1157 30174Thomas Nelson Inc. (615) 555-9079Harber, L. H. 12 $9.30214390 1171 30174Thomas Nelson Inc. (615) 555-9079Harber, L. H. 4 $7.40214390 1187 30174Thomas Nelson Inc. (615) 555-9079Harber, L. H. 3 $22.00214390 1224 30174Thomas Nelson Inc. (615) 555-9079Harber, L. H. 14 $15.20214390 1226 30174Thomas Nelson Inc. (615) 555-9079Harber, L. H. 11 $12.90214418 1250 30174Thomas Nelson Inc. (615) 555-9079Harber, L. H. 1 $11.60214418 1175 30174Thomas Nelson Inc. (615) 555-9079Harber, L. H. 8 $11.70214418 1114 30174Thomas Nelson Inc. (615) 555-9079Harber, L. H. 10 $9.50214460 1141 30139Cavco Industries Inc. (602) 555-6141Golkin, David 9 $7.90214460 1136 30139Cavco Industries Inc. (602) 555-6141Golkin, David 3 $7.00214460 1143 30139Cavco Industries Inc. (602) 555-6141Golkin, David 1 $6.30214460 1149 30139Cavco Industries Inc. (602) 555-6141Golkin, David 20 $6.00214460 1207 30139Cavco Industries Inc. (602) 555-6141Golkin, David 3 $8.40214460 1104 30139Cavco Industries Inc. (602) 555-6141Golkin, David 16 $5.30214480 1207 30125Alamo Group Inc. (210) 555-1483Maul, Duane A. 20 $8.40214480 1143 30125Alamo Group Inc. (210) 555-1483Maul, Duane A. 1 $6.30214480 1136 30125Alamo Group Inc. (210) 555-1483Maul, Duane A. 18 $7.00214480 1250 30125Alamo Group Inc. (210) 555-1483Maul, Duane A. 4 $11.60

Page 35: Structure

A337 - Reed Smith 35

2nd Normal FormInvoiceID InventoryID Quantity

214123 1207 10214123 1191 15214123 1101 10214123 1143 1214390 1157 12214390 1171 4214390 1187 3214390 1224 14214390 1226 11214418 1250 1214418 1175 8214418 1114 10214460 1141 9214460 1136 3214460 1143 1214460 1149 20214460 1207 3214460 1104 16214480 1207 20214480 1143 1214480 1136 18214480 1250 4

InvoiceID CustomerID CompanyName PhoneNumber Contact214123 30139Cavco Industries Inc. (602) 555-6141 Golkin, David214390 30174Thomas Nelson Inc. (615) 555-9079 Harber, L. H.214418 30174Thomas Nelson Inc. (615) 555-9079 Harber, L. H.214460 30139Cavco Industries Inc. (602) 555-6141 Golkin, David214480 30125Alamo Group Inc. (210) 555-1483 Maul, Duane A.

InventoryID UnitPrice1101 $8.101104 $5.301114 $9.501136 $7.001141 $7.901143 $6.301149 $6.001157 $9.301171 $7.401175 $11.701187 $22.001191 $4.50

1207 $8.401224 $15.201226 $12.901250 $11.60

Page 36: Structure

A337 - Reed Smith 36

3rd Normal FormInvoiceID InventoryID Quantity

214123 1207 10214123 1191 15214123 1101 10214123 1143 1214390 1157 12214390 1171 4214390 1187 3214390 1224 14214390 1226 11214418 1250 1214418 1175 8214418 1114 10214460 1141 9214460 1136 3214460 1143 1214460 1149 20214460 1207 3214460 1104 16214480 1207 20214480 1143 1214480 1136 18214480 1250 4

InventoryID UnitPrice1101 $8.101104 $5.301114 $9.501136 $7.001141 $7.901143 $6.301149 $6.001157 $9.301171 $7.401175 $11.701187 $22.001191 $4.50

1207 $8.401224 $15.201226 $12.901250 $11.60

InvoiceID CustomerID214123 30139214390 30174214418 30174214460 30139214480 30125

CustomerID CompanyName PhoneNumber Contact30125Alamo Group Inc. (210) 555-1483Maul, Duane A.30139Cavco Industries Inc. (602) 555-6141Golkin, David30174Thomas Nelson Inc. (615) 555-9079Harber, L. H.