Answer : D
Select deptname
it says we are selecting Department.
from Employee
Both above put together says we are selecting Dept name just by considering employee Table
where sex=’M’
It says we are selecting Male Employee.
group by dept name having
avg (salary)
it says we are grouping all the male employee in a Department whose avg salary is something
> {select avg (salary) from Employee}
This Last Comparison says we have selected something which is greater then the right side of comparison Operator
So What we have selected is
Average salary of male employees in a department is more than average salary of the organization