Written by students who passed Immediately available after payment Read online or as PDF Wrong document? Swap it for free 4.6 TrustPilot
logo-home
Other

INF3707 Assignment 1 solution 2025

Rating
5.0
(1)
Sold
9
Pages
6
Uploaded on
15-03-2025
Written in
2024/2025

Question 1 First things first, before you start with your assignment, make sure that your MySQL server and MySQL Workbench are installed and working. The prescribed book provides the procedures for doing this in appendix A (Windows) and B (macOS). The appendices were uploaded to Additional Resources on myUnisa. Secondly, on myUnisa, under Additional Resources, download the folder mgs_ex_starts, it contains some script files that you need for this assignment and other assignments, 2, 3 and 4. In the mgs_ex_starts folder, use the script file create_my_guitar_ to create the My Guitar Shop database. After running the scripts, the Output window displays messages that indicate whether the script was executed successfully. Take the screenshot, and paste it on your answer sheet to show that the database is installed correctly. The screenshot should show the My Guitar Shop database schema on your Workbench. View the data contained in the Categories table. To view the Categories table data, run a select query. Take the screenshot of the query and the output, and paste it on your answer sheet. Navigate through the database objects and view the column definition for the Categories table. Take the screenshot of the column definition and paste it on your answer sheet. Write a SELECT statement that returns four columns from the Products table: product_code, product_name, list_price, and discount_percent. Add an ORDER BY clause to this statement to sort the result by list_price in descending order. Take the screenshot of the query and the output and paste it on your answer sheet. Write a SELECT statement that returns the product_name and list_price columns from the Products table. Return one row for each product that has the same list price as another product. Hint: Use a self-join to check that the product_id columns aren't equal but the list_price columns are equal. Order the output by the product_name column. Take the screenshot of the query and the output and paste on your answer sheet

Show more Read less
Institution
Course

Content preview

INF3707 ASSIGNMENT 1 2025
SOLUTION

, Question 1
First things first, before you start with your assignment, make sure that your MySQL
server and MySQL Workbench are installed and working. The prescribed book provides
the procedures for doing this in appendix A (Windows) and B (macOS). The appendices
were uploaded to Additional Resources on myUnisa. Secondly, on myUnisa, under
Additional Resources, download the folder mgs_ex_starts, it contains some script files
that you need for this assignment and other assignments, 2, 3 and 4. In the
mgs_ex_starts folder, use the script file create_my_guitar_shop.sql to create the My
Guitar Shop database. After running the scripts, the Output window displays messages
that indicate whether the script was executed successfully. Take the screenshot, and
paste it on your answer sheet to show that the database is installed correctly. The
screenshot should show the My Guitar Shop database schema on your Workbench. (10
marks)




Explanation of what the script does:
This script creates the my_guitar_shop database in these steps:
1.​ Database Initialization
Drops any existing database named my_guitar_shop to start fresh.
Creates a new database my_guitar_shop and selects it for use.
2.​ Table Creation with the following tables:
Categories: Stores product categories (e.g., Guitars, Basses).
Products: Lists items for sale, linked to categories via category_id.
Customers: Contains customer details, including email and passwords (hashed).
Addresses: Stores customer addresses, linked to customers.

Written for

Institution
Course

Document information

Uploaded on
March 15, 2025
Number of pages
6
Written in
2024/2025
Type
OTHER
Person
Unknown

Subjects

$6.26
Get access to the full document:

Wrong document? Swap it for free Within 14 days of purchase and before downloading, you can choose a different document. You can simply spend the amount again.
Written by students who passed
Immediately available after payment
Read online or as PDF

Reviews from verified buyers

Showing all reviews
1 year ago

5.0

1 reviews

5
1
4
0
3
0
2
0
1
0
Trustworthy reviews on Stuvia

All reviews are made by real Stuvia users after verified purchases.

Get to know the seller

Seller avatar
Reputation scores are based on the amount of documents a seller has sold for a fee and the reviews they have received for those documents. There are three levels: Bronze, Silver and Gold. The better the reputation, the more your can rely on the quality of the sellers work.
CrystalIndigo University of South Africa (Unisa)
Follow You need to be logged in order to follow users or courses
Sold
490
Member since
6 year
Number of followers
226
Documents
73
Last sold
1 week ago
CrystalIndigo Solutions

providing all solutions to all computer science modules

4.1

53 reviews

5
27
4
14
3
6
2
1
1
5

Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Working on your references?

Create accurate citations in APA, MLA and Harvard with our free citation generator.

Working on your references?

Frequently asked questions