I have a Employee table with columns
ename,eid,salary,deptno. How to retrieve sum of salary for
each deptno?
Answer Posted / sudarsan
SELECT
DeptNo AS Department,
Count(DeptNo) AS Dept_Count,
Sum(Salary) AS Salary_DeptWise FROM Employee
GROUP BY DeptNo
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is trigger with example?
Are views faster than queries?
What is the size of partition table?
Cite the differences between execution of triggers and stored procedures?
What is a unique key?
what does myisamchk do? : Sql dba
Is the primary key an index?
What is forward declaration in pl sql?
Why do we go for stored procedures?
What is pl sql and why it is used for?
What is embedded sql in db2?
Can we join two tables without common column?
How to set up sql*plus output format in oracle?
Explain some predefined exceptions.
How to pronounce postgresql?