Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

this ERD REPRESENT THE ONE BELOW BECAUSE IN VERIOUS CHASE (please i repeat this ERD is thesame as the one Q1 please don't thing is

this ERD REPRESENT THE ONE BELOW BECAUSE IN VERIOUS CHASE (please i repeat this ERD is thesame as the one Q1 please don't thing is another question thank)

image text in transcribedimage text in transcribedimage text in transcribedimage text in transcribedand this program should have 2 or more screenshot to see if it works on the SQL DEVELOPER THANKS and this is the forth time i'm posting this

client C_number(pk) C name C address C city C state C_zip C_phone Status C_contact_name Invoice | number(PK) C_number(FK) | date Shipping intructions Payment terms vendor V_id(PK) V name V city V_zip V contact name INVOICED PRODUCT | number(pk)(fk) p_number(pk)(fk) Quantity V_city V_zip V contact name INVOICED_PRODUCT |_number(pk)(fk) P number(pk)(fk) Quantity PRODUCT P_number(PK) p_description P_unit_price V_ID(FK) Assignment 2 DDL & DML operations How to submit the work: Save screen capture for each query along with your name, lab/assignment name and question commented in screen shot in word document and submit in Blackboard. Name your document as yourname_DB_lab/assignment name. (see rubric below for points) Create and execute statements to perform the following DML activities. Save the changes permanently to the database. Start recording screen captures from Naming convention for constraints is as follows: Tablename_column_name_constriant_Type Q.1 CLIENT INVOICE Number PK Number FK) INVOICED PRODUCT Number PFK) P Number) Number Name Address C_City C State C_ZIP Phone Status C_contact_name Shipping Instructions Pyment terms PRODUCT VENDOR Y_ID IPK V_Name V_City V 2ip 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. 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. C. 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. STATE REFERRED CUSTOMER 1021 1022 REGION LASTNAME Your last name Any but not from ADRESS 44 SHIRLEY AVE 514 S. MAGNOLIA ZIP 60185 CITY WEST CHICAGO ORLANDO EMAIL Yourhumberemail FL SE ANY FIRSTNAME Your first name Any but not from class Any but not from class Any but not from class 1023 ANY Any but not from class Any but not from class 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

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Securing SQL Server Protecting Your Database From Attackers

Authors: Denny Cherry

2nd Edition

1597499471, 978-1597499477

More Books

Students also viewed these Databases questions