Question: [20 points] Write SQL queries to retrieve the following information from t (See schema on last page). 6) he PetStore database a. What is the
[20 points] Write SQL queries to retrieve the following information from t (See schema on last page). 6) he PetStore database a. What is the average list price for each merchandise category? b List all the cities with 'new' in their name. Show the city name, population 1990, and state. Organize results by state name By total dollar value (not just quantity), which customer has bought the most stuff? Rank from highest to lowest. Ignore the Walkin customer id 1. c. What was the greatest increase in population from 1980 to 1990. This should be a single result answer. d. e. Rank the number of adoptions by adoption group source from lowest to highest. f. Which suppliers did the PetStore never buy anything from? Show the name and ID. 7) EXTRA CREDIT [3 points] Identify three relational database software providers. Page 6 of 9 AdoptionGroup Animal AdoptionlD AdoptionSource ContactName ContactPhone AnimalID Name Category Breed DateBorn Gender Registered Color Photo ImageFile Imageheight ImageWidth Adoption!D SalelD Donation Breed Category Breed Employee City EmployeelD LastName FirstName Phone Address ZIPCode Category Category Registration Supplier SupplierlD Name ContactName Phone Address ZIPCode CitylD CitylD ZIPCode City State AreaCode Population1990CitylD Population1980 Countny TaxPayerl DateHired DateReleased ManagerlD Employeelevel Title Sale SalelD SaleDate EmployeelD CustomerlD Sales Tax Customer CustomerlD Phone FirstName LastName Address ZIPCode CitylD Latitude Longitude Merchandise ItemID Description ListPrice Saleltem MerchandiseOrder PONumber OrderDate ReceiveDate SupplierlD EmployeelD ShippingCost Orderltem PONumber emiD Quantity SalelD QuantityOnHandItemlD Quantity SalePrice Cost !Category
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
