hi friends please answer this question ASAP:-
how to count the no. of employee in a each department
or
no. of employee in each location by using emp/dept table

Answer Posted / madhu sudhan g

Hiii

Try this query it will give you the answer


select count(1) as EmpCount,EmployeeName from EMP
GROUP BY DepartmentName

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is wrong with sql server client libarary dll, ntwdblib.dll?

556


wat wil hapn if we give the both read and deny read permission to user?

1656


What is a file group?

618


What to perform pattern match with the like operator?

482


What is transaction server explicit transaction?

540






List the advantages of using stored procedures?

560


What do you mean by tablesample?

637


How do I view a stored procedure in sql server?

515


What is the use of @@spid?

572


How can I create a report based on a query? : sql server management studio

558


How to defragment indexes with alter index ... Reorganize?

584


In case you have filters in your report, when filters will be applied in cached report instance?

79


Explain security with sql azure?

161


How can sql server instances be hidden?

526


Are connections to sql server encrypted?

572