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

Assignment Help:

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


Related Discussions:- Find out employee who draws salary more than average

What is meant by object-oriented data model, What is meant by object-orient...

What is meant by object-oriented data model? The object-oriented paradigm is based on encapsulation of data and code related to an object in to a one unit, whose contents are n

Create student db and perform delete operation, Create Student DB and perfo...

Create Student DB and perform delete operation? STUDENT (name, student#, class, major) COURSE (course name, course#, credit hours, department) SECTION (section identifier, co

Explain natural join, Explain natural join? Natural Join - Similar as...

Explain natural join? Natural Join - Similar as equi-join except in which the join attributes (having similar names) are not involved in the resulting relation. Only one sets

Identify the candidate keys, Consider the following six relation schemes an...

Consider the following six relation schemes and their corresponding sets of functional dependencies. In each case identify a. All the candidate keys b. The highest normal for

Explain tuple variable, Define tuple variable? Tuple variables are used...

Define tuple variable? Tuple variables are used for comparing two tuples in the same relation. The tuple variables are explained in the from clause by way of the as clause.

Implementation of association as an object, Implementation of association a...

Implementation of association as an object Implement as a separate association object, independent of either class, as in Figure. An association object is a group of pairs

Describe the major steps in the implementation process, Question: (a) ...

Question: (a) One of the steps in the five-step problem-solving model is implementation. Implementation is considered a key step in the problem-solving model. A problem may be

What is a cascading update, What is a cascading update? Referential int...

What is a cascading update? Referential integrity constraints needs that foreign key values in one table correspond to primary key values in another. If the value of the primar

Illustrate the definition of the classes and operation, The definition of t...

The definition of the classes and operation can often be adjusted to increase the amount of inheritance". Justify the above statement.   Adjustment of Inheritance The def

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd