tweichle / w3resource-SQL-Exercises

Exercises to help improve SQL skills
https://www.w3resource.com/sql-exercises/
37 stars 77 forks source link

sql query #1

Open kiran788786767 opened 1 year ago

kiran788786767 commented 1 year ago

Return the employee that have salary that is not in the range between the minimum salary and maximum salary of their job. For example you need to return Adam’s if their salary is 6000 and they work a. job that has Min_salary 7000 and Max_salary 10000.

nunnanaveen08 commented 3 months ago

/ 5. Write a query to display the employee name (first name and last name), employee id and salary of all employees who report to Payam. / SELECT EMPLOYEE_ID, CONCAT(FIRST_NAME, " ", LAST_NAME) AS EMPLOYEE_NAME, SALARY, MANAGER_ID FROM EMPLOYEES WHERE MANAGER_ID IN (SELECT MANAGER_ID FROM EMPLOYEES WHERE FIRST_NAME= "Payam"); IN THE SOLUTION instead of manager_id considered employee_id which is not driving solution.................