Question: Create a View (3 points) Create a SQL view called VENDOR_PRODUCTS_TOTALS that shows the vendor name, vendor code and the total number of products provided

Create a View (3 points) Create a SQL view called VENDOR_PRODUCTS_TOTALS that shows the vendor name, vendor code and the total number of products provided by the vendor but only for vendors providing two or more products. When done, issue a select * from VENDOR_PRODUCTS_TOTALS statement to display the contents of view VENDOR_PRODUCTS_TOTALS. You should use the CREATE OR REPLACE VIEW VENDOR_PRODUCTS_TOTALS AS SELECT command for this question [hint: you should have 5 rows of output].

Update Records (3 points) Execute a select * from product; statement. Create an SQL update statement which doubles the P_DISCOUNT for all products provided by vendors in TN or FL. Issue another select * from product; statement after the update. Do a rollback [hint: you should have 9 rows updated before the rollback].

Delete Records (3 points) Execute a select * from LINE; statement. Create an SQL delete statement to delete invoice lines that include 2 or more units of product code 23109-HB. Issue another select * from LINE; statement after the delete. Do a rollback [hint: you should have 1 row deleted before the rollback].

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!