Find out employee who draws salary more than average , Database Management System

Example: Find out the employee who draws a salary more than the average salary of all the departments.

EMPNO

ENAME

JOB

SAL

DEPTNO

7566

Nirmal

MANAGER

2975

10

7788

Kailash

ANALYST

3000

10

7839

Karuna

PRESIDENT

5000

20

7902

Ashwin

ANALYST

3000

20

7905

Ashwini

MANAGER

4000

20

 

 

SELECT EMPNO, ENAME, JOB, SAL

FROM EMP

WHERE SAL> ALL (SELECT AVG (SAL)

FROM EMP

                  GROUP BY DEPTNO);

 OUPUT:

EMPNO

ENAME

JOB

SAL

7839

Karuna

PRESIDENT

5000

Posted Date: 3/11/2013 3:58:32 AM | Location : United States







Related Discussions:- Find out employee who draws salary more than average , Assignment Help, Ask Question on Find out employee who draws salary more than average , Get Answer, Expert's Help, Find out employee who draws salary more than average Discussions

Write discussion on Find out employee who draws salary more than average
Your posts are moderated
Related Questions
Differentiate between a subquery and a join If we need to acquire information from one or more tables after that either subquery or join can be used. If the columns which are t

How nulls are treated in comparison operator? Along with comparison (relational) operators, the null values are ignored as we cannot derive the relation along with the given op

Explain the concepts of relational data model? Relational Data Model - The relational model was first introduced through Prof. E.F. Codd of the IBM Research in the year 1970

Define Deadlock avoidance These protocols as well ensure that the system will never enter a deadlock state although the way it is done is different from deadlock prevention. I

In this assignment, you will create a program that works with multiple tables. In this assignment, you will work with the factory and sales tables. 1. Create a new project nam


Attributes and its types explain?

Define deadlock prevention. Deadlock prevention is a set of methods for ensuring that at least one of the four essential conditions like mutual exclusion, hold and wait, no pre

The figure below depicts the conceptual diagram of a banking system. (a) Describe one example relevant to the system in figure, for each of the 4 types of enterprise appl

Economics: It is now usually accepted that it costs less to make a system of smaller computers with the equivalent power of a one large computer. It is more cost-effective to get s