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
Illustrate about the advanced object design Advanced object design is a complex task. The objects discovered through analysis serve as a skeleton of design. The operations reco

The PROJECT operation The project operation is used to choose the records with specified attributes as discarding the others based on some related criteria. This is denotes as ∏

Define query optimization. Query optimization refers to the process of search the lowest -cost method of evaluating a given query.

In this programming assignment, you will develop a simple database of student records. Here are the requirements: 1) A student record contains a name and a number. We assume tha

What are the factors to be taken into account when choosing a RAID level? A) Monetary cost of extra disk storage requirements. B) Performance requirements in terms of number

tell me the functionality,advantages and disadvantages of student database

Define an abstraction by which relationships are treated as higher level entities Ans: Aggregation.  It is an abstraction by which relationships are treated as higher level

Describe Participation Constraints? Participation Constraints - The participation constraint exacts whether the existence of an entity depends on its being related to another

Determine the term- Active values An active value is that has dependent values. Every dependent value registers itself with active value that contains a set of dependent values

What is Asterisk in SQL? Asterisk (*): In SQL, the columns for all the tables and views in the FROM clause will be displayed.