Home
Recent Q&A
Java
Cloud
JavaScript
Python
SQL
PHP
HTML
C++
Data Science
DBMS
Devops
Hadoop
Machine Learning
Azure
Blockchain
Devops
Ask a Question
Write an Oracle SQL query to find employees who earn more than their managers.
Home
Oracle
Write an Oracle SQL query to find employees who earn more than their managers.
0
votes
asked
Jan 21
in
Oracle
by
rajeshsharma
Write an Oracle SQL query to find employees who earn more than their managers.
oraclesqlquery
Please
log in
or
register
to answer this question.
1
Answer
0
votes
answered
Jan 21
by
rajeshsharma
SELECT emp.*
FROM Employee emp
INNER JOIN Employee mgr ON emp.manager_id = mgr.employee_id
WHERE emp.salary > mgr.salary;
Related questions
0
votes
Q: Write an Oracle SQL query to find the average salary of employees within each department.
asked
Jan 21
in
Oracle
by
rajeshsharma
oraclesqlquery
0
votes
Q: Write an Oracle SQL query to ensure only users with the manager role can insert rows into the performance_reviews table.
asked
Jan 23
in
Oracle
by
SakshiSharma
oraclesqlquery
0
votes
Q: Write an Oracle SQL query to get the date and time of the last 10 logins for a specific user.
asked
Jan 21
in
Oracle
by
rajeshsharma
oraclesqlquery
0
votes
Q: Write an Oracle SQL query to find the names of employees not assigned to any project.
asked
Jan 23
in
Oracle
by
SakshiSharma
oracle-sql
0
votes
Q: Write an Oracle SQL query to find the five most common names in the Employee table.
asked
Jan 23
in
Oracle
by
SakshiSharma
oracle-query
0
votes
Q: You have an Employees table with columns for employee names and their respective managers
asked
Jan 23
in
Oracle
by
SakshiSharma
oracle-query
0
votes
Q: Write the SQL query to get the third maximum salary of an employee from a table named employees.
asked
Nov 8, 2021
in
Sql
by
rajeshsharma
sql-query
0
votes
Q: Imagine you want to identify employees who are eligible for promotions based on their years
asked
Jan 23
in
Oracle
by
SakshiSharma
oracle-query
0
votes
Q: You want to create a list of managers and the number of employees reporting to them
asked
Jan 23
in
Oracle
by
SakshiSharma
sql-query
0
votes
Q: How to write an SQL query to find students' names start with 'A'?
asked
Nov 8, 2021
in
Sql
by
rajeshsharma
sql-query
...