Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Hi I need help with mysql questions, please thank you Link to sql file on google drive: https://drive.google.com/file/d/1nBXFuujXudCjzyvQ282NWB3qZhXplvmr/view?usp=drivesdk 7. Write a query to show the
Hi I need help with mysql questions, please thank you
Link to sql file on google drive: https://drive.google.com/file/d/1nBXFuujXudCjzyvQ282NWB3qZhXplvmr/view?usp=drivesdk
7. Write a query to show the total number of employees for each territory. Show the number of employees first and then the territory description. Sort the results by the number of employees per territory with the highest number of employees first. If there are territories with the same number of employees, then sort the results by territory description within number of employees. Below is a sample of the expected output. New York danta Columbia Dalas 8. Now show the number of employees by region. Below is the expected result including sort order and column names Number of Employees RegionDescription 19 15 Eastem Westem Northem 9. Show the supervisor(s) that have 4 or more employees. It is okay to hard code the 4 this time. You must use the appropriate HAVING clause. Here is the expected result. Notice the column headers. Supervisor Number of employees Fuller, Andrew 5 10. Show only the territory with the most employees. You must use aggregate functions in the query to only show the correct territory. Your query must use a HAVING clause with a subquery. Hint: Use your solution to #7 as a derived table for the subquery in the HAVING clause. Here is the entire expected result. Number of EmployeesTetoryDesorption New YorkStep 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