Write a stored procedure for emplpoyee and department table
to get DeptName which having no employee.
Table Structure-
Emp-Emp_Id,Emp_Name,Dept_id
Dept-Dept_Id,Dept_Name

Answer Posted / vinoth kumar

select * from department where Dept_id
not in(select Dept_id
from employee)

Is This Answer Correct ?    4 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What does man by sql wildcard characters in sql server?

620


Is it possible to have clustered index on separate drive from original table location?

609


How to get the query of a table in sql server?

579


What is server-level principal?

108


What are recommended options to be used while using db mirroring? : sql server database administration

655






What is hot add cpu in sql server 2008?

603


Why transaction is important?

637


What is history table in sql server?

579


Tell me what is the significance of null value and why should we avoid permitting null values?

618


What is the security principal at the server level that represents your session?

638


What functions can a view be used to performed?

719


What are partitioned views and distributed partitioned views?

705


How do I uninstall sql server 2014?

593


When is update_statistics command used?

675


What is the contrast between sql and pl/sql?

696