Employee 7566 salary is extra than salary of employee 7788, Database Management System

Example: -Show the employees whose job title is the similar as that of employee 7566 and salary is extra than the salary of employee 7788.

Let consider the given partial relation EMP. Let us make some sub-queries for them

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 ENAME, JOB

FROM EMP

WHERE JOB =   (SELECT JOB  

                            FROM EMP

                            WHERE EMPPNO = 7566)

                 AND SAL > (SELECT SAL

                                       FROM EMP

                                       WHERE EMPPNO=7788);

 

Output: Job title for the employee 7566 occurs to be 'MANAGER')

ENAME

JOB

Ashwini

MANAGER

Posted Date: 3/11/2013 3:42:43 AM | Location : United States







Related Discussions:- Employee 7566 salary is extra than salary of employee 7788, Assignment Help, Ask Question on Employee 7566 salary is extra than salary of employee 7788, Get Answer, Expert's Help, Employee 7566 salary is extra than salary of employee 7788 Discussions

Write discussion on Employee 7566 salary is extra than salary of employee 7788
Your posts are moderated
Related Questions
What is Specialization? Specialization: Specialization permits you to describe new types of information (new structural types or latest domains of information), although reusin

what is er digram given that example of hospital,bank and library er digram.

Text Processing: Use readLines to read SOU.txt into R. Create a vector called Pres containing the names of the presidents giving each speech. To do this, rst identify the lin

Explain the functions of data manager? Functions of Data Manager : - Convert operations in user's queries coming directly through query processor or indirectly in an applicatio

describe objectivde of file organisation

What is object containment? References among objects can be used to model dissimilar real-world concepts.

In which format database schema is written ? Data base schema is written in the DDL format.

Determine the Strong and Weak Entity Based on the method of foreign key, there might be arise a situation when we have to relate an entity having a primary key of its own and a

Give detail description on Transactions. - Using transactions we can group all SQL commands into a single unit. - Transaction begins with some task and finishes only when a

Consider the relation schemas as follows. works (person name, company name, salary); lives (person name, street, city); located in(company name, city); managers (person name