424 views
0 votes
0 votes

1 Answer

0 votes
0 votes

Sql query will be:

Select emp_name from Emp E1(Select dept_name,AVG(Salary) as A from Emp  E2 Group by(dept_name)) 

where E1.salary>E2.A and E1.dept_name=E2.dept_name.

edited by

Related questions

0 votes
0 votes
1 answer
3
rayhanrjt asked Jan 6, 2023
787 views
Write SQL command to find DepartmentID, EmployeeName from Employee table whose average salary is above 20000.
2 votes
2 votes
1 answer
4
Subhrangsu asked Jun 18, 2022
451 views
Write SQL query to show all employees hired on June 4,1984 (non-default format)emp(empno,ename,job,mgr,hiredate,sal,comm,deptno)