Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Q.1 CLIENT INVOICE INVOICED PRODUCT Number(PO C_Name C Address C_City State Zip Phone Status C_contact_name I_Number(PK) NumberIFK) I date Shipping Instructions Pyment terms Number PMFK)
Q.1 CLIENT INVOICE INVOICED PRODUCT Number(PO C_Name C Address C_City State Zip Phone Status C_contact_name I_Number(PK) NumberIFK) I date Shipping Instructions Pyment terms Number PMFK) P_NumberPOUFK) Quantity PRODUCT VENDOR Y_01 V_Name V_City Vip V_Contact_Name P_Number P_Description Punt Price V_IDF) a. Create INVOICED_PRODUCT table including constraints as shown in ERD above. Name all constraints. b. View the constraints INVOICED_PRODUCT table from USER_CONSTRAINTS as well as from USER_CONS_CONSTRAINTS. Q.2 Start capturing screens from question 2g. a. Create a TEMP_CUST table from existing table CUSTOMERS. b. View the contents and constraints of TEMP_CUST table and notice no constraints have been added to the new created table. C. Create a TEMP_ORDERS table from existing table ORDERS. d. View the contents and constraints of TEMP_ORDERS table. e. Add PRIMARY KEY constraint on TEMP_CUST table and name the constraint. f. Add PRIMARY KEY and FOREIGN KEY constraint on TEMP_ORDERS table to make sure the value entered in TEMP_CUST's CUSTOMER# column exists in TEMP_CUST'S CUSTOMER# column. Name both constraints g. View the constraints of TEMP_CUST and TEMP_ORDERS table just like Q.1. h. Create a script to allow a user to add new customers (providing prompts to the user) to the TEMP_CUST table. i. Add the following CUSTOMERS, using the script created in the previous step. No value needs to be entered at the prompt if it should be set to the DEFAULT column value. Display newly added rows from TEMP_CUST table. CUSTOMERU 1021 STATE REFERRED REGION ADRESS 44 SHIRLEY AVE 514 S. MAGNOLA WEST CHICAGO ORLANDO ZIP 60185 32806 EMAIL YourHumberemail ANY 1022 FL SE LASTNAME Your last name Any but not from class Any but not from class Any but not from class FIRSTNAME Your first name Any but not from class Any but not from class Any but not from class 1023 ANY 1024 579 WILSON COURT GRAND RAPIDS MI 49503 ANY j. Change the ADDRESS of the CUSTOMER 1019 to 6 BRIARWOOD AVE., CITY to LIBERTYVILLE, STATE to IL and ZIP to 60048. k. Remove customer 1003 from the TEMP_CUST and view contents of TEMP_CUST table. 1. Make the changes permanent. Q.3. Execute a DML statement to accomplish each of the following actions. Each statement produces a constraint error. Document the error number and message, and briefly explain the cause of the error and how to fix it. If your DML statement generates a syntax error rather than a constraint violation error, revise your statement to correct any syntax errors for example 'not enough values' or 'invalid identifier' or 'table not found' etc. You can view constraints to identify constraints in respective tables. a. Add an order using the following data into TEMP_ORDERS table: ORDER# = 1020, CUSTOMER# = 1010, ORDERATE = 23 FEB 2021. b. Add an order using the following data into TEMP_ORDERS table: ORDER# = 1021, CUSTOMER# = 1024, ORDERATE = 23 FEB 2021. C. Add an order using the following data into TEMP_ORDERS table: ORDER# = 1021, CUSTOMER# = 1010. d. Add new customer with customer# =1025 and lastname=SARASUA leaving firstname blank. Rubric DDL and DML operations
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started