Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Using the My Guitar Shop database you installed in Module 1 , develop the following queries. To test whether a table has been modified correctly

Using the My Guitar Shop database you installed in Module 1, develop the following queries.
To test whether a table has been modified correctly as you do these exercises, you can write and run an appropriate SELECT statement.
1. Write an INSERT statement that adds this row to the Categories table:
category_name: Brass
Code the INSERT statement so MySQL automatically generates the category_id column. Execute the query and take a screenshot of the query and the results.
2. Write an UPDATE statement that modifies the row you just added to the Categories table. This statement should change the category_name column to Woodwinds, and it should use the category_id column to identify the row. Execute the query and take a screenshot of the query and the results.
3. 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. Execute the query and take a screenshot of the query and the results.
4. Write an INSERT statement that adds this row to the Products table:
product_id:
category_id:
product_code:
product_name:
description:
list_price:
discount_percent:
date_added:
The next automatically generated ID
4
dgx_640
Yamaha DGX 64088-Key Digital Piano
Long description to come.
799.99
0
Todays date/time.
Use a column list for this statement. Execute the query and take a screenshot of the query and the results

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

Advances In Databases And Information Systems Uropean Conference Adbis 2020 Lyon France August 25 27 2020 Proceedings Lncs 12245

Authors: Jerome Darmont ,Boris Novikov ,Robert Wrembel

1st Edition

3030548317, 978-3030548315

More Books

Students also viewed these Databases questions