Write a SQL query to display employee who is earning maximum salary. SELECT first_name,salary FROM employees WHERE salary=(SELECT MAX(salary) FROM employees); Another way: Using row num SELECT *FROM (SELECT row_number()… Continue reading "Query to find Max Salary along with Employee name"
Category: SQL Interview Question
We have Employees Table. Write a SQL query to display employee name along with Manager name. To achieve this we have to use self join SELECT a.employee_id,a.first_name,b.employee_id manager_id,b.first_name manager FROM… Continue reading "Query to find manager of employee in sql"