Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

.\'ll MetroPCS? 12:44 PM mga.view.usg.edu 2908 Electric Ligh 330 Group: Six Peop

ID: 3708646 • Letter: #

Question

.'ll MetroPCS? 12:44 PM mga.view.usg.edu 2908 Electric Ligh 330 Group: Six People in Search of a Life 3743 Nine Stories 906 The Soul of a New Machine 163 Travels with Charky 5790 Catch-22 6128 Jarz 6328 Band o Brothers 669X A Guide to SOL 90 Franny and Zooey 7405 East ot Eden 443 Harry Potter and the Goblet of Fire 7359 The Fall 8092 Godel, Escher, Bach 8720 When Rabbit Howls 9611 Black Hlouse 9627 Song of Selomon 970 The Grapes of Wrath 9882 Slay Ride 9883 The Catcher in the Rye 993 To Kill aMockingbird FS POE 1400 B PSY 10.40 LB FIC 99Y BY SC 116 PE TRA 7.95 SC FIC 1200 Y PL FIC 1295 Y TO HIS 960 CT CMP 37.95 LB FIC 99Y PE FIC 125 Y ST SF 18.16 VB FC 00Y BA PHI 14.00 Y P PSY 629 RH HOR 188 PL FIC 14 Y PE FIC 130 Y JP MYS 699 LB FIC 399Y HC FIC 18. N First, create a database using the attached sql file (henry bookstore.sql) and MySQL Workbench. Then write SQL SELECT commands to answer the following queries, test your answer to each query using the MySQL database, and submit the screenshots of the test results. (Please refer to the tutorial video, MySQL Installation and How to Run Script, if you don't know how to create a database using MySQL Workbench). a. List the names, locations, and the number of employees of all of the branches. b. List the codes and names of the publishers that are located in New York c. List the books publshed by Penguin USA d. List the authors whose last name starts with S e. List the books whose price is greater than $10.00 and that are f. List the books whose type is fiction or whose price is greater than S10.00 g. List the branches that have more than 8 employees. h. List the most expensive book. i. List the cheapest book. j. List the books between S10.00 and S20.00 k. List the books published by all of the publishers located in New York 1. List the average price of all books in each book type. m. List the e most expensive book in each book type Please do not hesitate to contact me if you have any questions.

Explanation / Answer

Solution:

Note 1: The first four subparts have been answered as per Chegg guidelines, please repost others.

Note 2: The columns of the table are not properly given, so queries are based on the assumption of the column name assumptions. Please modify accordingly.

a)

SELECT name, locations, COUNT(empID) FROM Employee GROUP BY branchID

b)

SELECT code, publisherName FROM Publisher WHERE location= 'New York'

c)

SELECT bookID FROM Publisher WHERE Publisher= 'Penguine USA'

d)

SELECT authorName FRoM Publisher WHERE authorName LIKE '%S'

I hope this helps if you find any problem. Please comment below. Don't forget to give a thumbs up if you liked it. :)