ASAP!!!
Please make sure that the query is runnable:)
I provided the schema for the DB. The answers for the questions below need to be answered by an SQL query.
Question 2.a: Which employee at Microsoft has the highest salary?
2.b: Find the average salary of all jobs excluding the highest-paid company, rounded to two decimal places.
2.c: How many people hold the maximum salary?
2.d: What is the most common salary?
Database Schema:
You are given a database for an employee management system. The table names are self-explanatory.
companies (ID, Name)
1. ID: The unique ID of the company
2. Name: The name of the company.
employees (ID, Name, Job_ID)
1. ID: The unique ID of the employee
2. Name: The name of the employee.
3. Job_ID: The job of that employee, referring to the jobs table.
jobs (ID, Company_ID, Name, Salary)
1. ID: The unique ID of a job
2. Company ID: The ID of the company associated with the job, referring to the companies table.
3. Name: The name of the job.
4. Salary: The salary of the job