779 views
0 votes
0 votes

 

2 Answers

2 votes
2 votes
$\text{answer should be b)}$$$\text{NOT EXISTS returns TRUE if there are no tuples in the result of nested query , and it returns }$$$\text{FALSE otherwise.}$

$\text{first subquery selects allprojects controlled by department 5, and the second subquery}$
$\text{selects all projects on which particular employee is working and the }$
$\text{difference of the first subquery result EXCEPT the second subquery result is }$
$\text{empty, it means that the employee works on all the projects and is therefore selected.}$
2 votes
2 votes

$\text{just go through it ,what I have done for each }$
$\text{employee the inner subquery will run inner query returns null }$
$\text{means that particular employee is working on all the project that are controlled}$
$\text{by department no. 5 and the query will return some value only when that particular employee}$


$\text{is not working on all projects controlled by dept. 5 }$

Related questions

0 votes
0 votes
1 answer
2
rayhanrjt asked Jan 6, 2023
720 views
Write SQL command to find DepartmentID, EmployeeName from Employee table whose average salary is above 20000.
2 votes
2 votes
1 answer
3
Subhrangsu asked Jun 18, 2022
432 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)
1 votes
1 votes
1 answer
4
Shubhanshu asked Dec 24, 2018
1,260 views
According to me it should be – “Retrieve the names of all students with a lower rank, than all students with age < 18 ”