Answered step by step
Verified Expert Solution
Question
1 Approved Answer
MYSQL Chapter 5 How to insert, update, and delete data Exercises appropriate SELECT statement. 1. Write an INSERT statement that adds this row to the
MYSQL
Chapter 5 How to insert, update, and delete data Exercises appropriate SELECT statement. 1. Write an INSERT statement that adds this row to the Categories table: Brass category name Code the INSERT statement so MySQL automatically generates the category_id column. Write an UPDA TE statement that modifies the row you just added to the Categories table. This statement should change the product_name column to "Woodwinds", and it should use the category id column to identify the row. Write a DELETE statement that deletes the row you added to the Categories table in exercise 1. This statement should use the category_id column to identify the row 2. 3. 4. Write an INSERT statement that adds this row to the Products table: product id category id: product_code product name: description: list price: The next automatically generated ID 4 dgx 640 Yamaha DGX 640 88-Key Digital Piano Long description to come. 799.99 discount percent Today's date/time. date added Use a column list for this statement. Write an UPDATE statement that modifies the product you added in exercise 4. This statement should change the discount-percent column from 0% to 35%. Write a DELETE statement that deletes the record with category_id 4 from the Categories table. 5. 6. When you execute this statement, it will produce an error since the category has related rows in the Products table. To fix that, precede the DELETE statement with another DELETE statement that deletes all products in this category. (Remember that to code two or more statements in a script, you must end each statement with a semicolon.)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