CIS336 Week 1 iLab1 PLEASE DOWNLOAD HERELABOVERVIEWScenario/SummaryThis lab will introduce you to the processes involved in defining one of the keycomponents of a data model; the relationship diagram (RD). In this lab, you willdraw a relationship diagram for two of the steps shown. Keep in mind when youare trying to decide which side of the relationship should be the "one" side andwhich should be the "many" that you must first decide which side has the primarykey, or unique identifier. Once you have decided the primary key of therelationship, you have identified the "one" side of the relationship. Note that for anRD, the foreign key "many" side of the relationship points to the primary key "one"side. The "one" side should have the arrowhead point of the connecting line. Thisis different than an entity/relationship diagram (ERD) that we will draw next week,where the "many" side has crows feet.This will familiarize you with how to set up MS Visio to draw database diagrams.Steps 1 - 3 below use the Customer, Order, and Employee tables of a simplifiedOrder Entry database. The Customer table records clients who have placedorders. The Order table contains the basic facts about customer orders. TheEmployee table contains facts about employees who take orders. The primarykeys of the tables are CustNo for Customer, EmpNo for Employee, and OrdNo forOrder.The following are the TABLE definitions for the first three tables showing thePRIMARY KEY constraints.TABLE Customer has the following attributesCustNoNUMBER(5)CustFirstNameVARCHAR2(20)CustLastNameVARCHAR2(30)
CustCityVARCHAR2(30)CustStateCHAR(2)CustZipCHAR(10)CustBalNUMBER(12,2)CustNo is thePRIMARY KEYTABLE Employee has the following attributesEmpNoNUMBER(5)EmpFirstNameVARCHAR2(20)EmpLastNameVARCHAR2(30)EmpPhoneCHAR(15)EmpNo is thePRIMARY KEYTABLE Order has the following attributesOrdNoNUMBER(5)OrdDate
DATECustNoNUMBER(5)EmpNoNUMBER(5)OrdNo is thePRIMARY KEYYour task for this lab is to create the required relationship diagram for steps 1 and2 using Microsoft Visio. Step 3 will require you to analyze the scenario given andpresent your own resolution to the question. Step 4 is an individual assignmentthat will introduce you to the group project and the process of identifying entitiesand attributes. When finished with the lab, you should have a complete diagramusing all 5 entities, a written explanation for #3, and two lists (entities andattributes) for Step 4.DeliverablesThe deliverable for this lab is a single MS Word document named"Lab1_solution_yourname" with the diagram for problems 1 and 2, the writtenanswer for the question in Step 3, and the lists of entities and attributes for theInitial Project Exercise (Step 4). You should copy and paste the diagram from MSVisio into a Word document and use this document for Steps 3 and 4.LABSTEPSSTEP 1: Drawing your first ER diagram TitleIdentify the foreign key columns in the table structures above and draw arelationship diagram depicting the relationships between the tables. In the Ordertable , the CustNo column references the Customer table and the EmpNo columnreferences the Employee table. For each relationship, identify the table on the "1"side of the relationship and the table on the "Many" side.STEP 2: Extending the ER diagram
Extend your relationship diagram from problem 1 by adding two tables (OrdLineand Product). Table definitions for the table structures and primary keysconstraints are shown below. You will need to identify the FOREIGN KEY(s) tocomplete this problem. When finished you should have a total of 5 tablesrepresented in your diagram for this problem. To copy and paste the diagram intoWord, select Edit from the menu and then Copy Diagram. Open a Worddocument and use CTRL-V to paste the diagram.TABLE Product has the following attributesProdNoCHAR(8)ProdNameVARCHAR2(20)ProdNo is thePRIMARY KEYTABLE OrdLine has the following attributesOrdNoCHAR(8)ProdNoCHAR(8)QtyNUMBER(5)The combination of OrdNo and Prodno is thePRIMARY KEYSTEP 3: Should a NULL be allowed?From examination of the sample data and your current understanding ofbusinesses in which orders could be placed either in person, over the phone, or
over the Internet, determine if it would be permissible for null values to be allowedfor the foreign key EmpNo in the Order table. This column would reference backto the EmpNo column in the employee table. Why or why not?OrdNoOrdDateCustNoEmpNoO165677702/11/2000C8543321O795989802/19/2000C8543321E8544399STEP 4: Initial Project ExerciseAlthough the overall project itself will be done as a group, this first exercise isdesigned as an individual effort and is intended to; (1) get you to read the projectspecifications, and; (2) introduce you to the first step in designing a databasefrom scratch. This little exercise will have you see how many entities andattributes you can find in the project specifications. In week three, you will workwith your assigned project team and compare notes on what you have found.This is not rocket science here so remember, you are looking for people, places,things, and events (entities) and the attributes that describe them.