IF( select count(*) from employees where DeptID= 100) > 0
PRINT ' there is employees in the department 100'
else
PRINT ' NO one is there in the department 100'
The above code snippet will check for whether the department 100 is having employees or not....