Maximum total compensation
You're given the following table showing information about employees at a company:
Using the table above, write a SQL query to return the emp_id of the employee with the highest total compensation. Make sure your query is able to handle potential ties (e.g. if there is a tie, should return all emp_ids that tie for the highest total compensation).
You can view/query the data in an interactive SQL fiddle here.
Subscribe to premium account to see the solution.Get premium now