From an Employee table, how will you display the record
which has a maximum salary?
Answers were Sorted based on User's Feedback
Answer / hari
select max(sal) from employee;
or
select * from employee where sal in(select max(sal) from employee);
| Is This Answer Correct ? | 0 Yes | 0 No |
Answer / venubabu addagada
SELECT DISTINCT
( e.emp_salary )
FROM
employee e
WHERE
&n = (
SELECT
COUNT(DISTINCT(e1.emp_salary) )
FROM
employee e1
WHERE
e1.emp_salary > e.emp_salary
);
| Is This Answer Correct ? | 0 Yes | 0 No |
Answer / sudeep mishra
select *
from employee
where salary = max sal
| Is This Answer Correct ? | 0 Yes | 1 No |
Answer / suresh babu
SELECT * FROM employees WHERE salary = (SELECT MAX(salary)
FROM employees);
This query will return the employee details,who getting
maximum salary.
| Is This Answer Correct ? | 0 Yes | 2 No |
Answer / jayshree
SELECT LAST_NAME,MAX(SALARY)
FROM EMPLOYEES
GROUP_BY SALARY;
| Is This Answer Correct ? | 2 Yes | 8 No |
How to test for null values?
what happens if you no create privilege in a database? : Sql dba
How many developers work on postgresql?
Give an example of Full Outer Join?
What is left join in postgresql?
What is pl sql commands?
What is secondary key?
How can i insert data inro a table with 3 columns using FORALL?
what is the syntax used for partition in tsql? : Transact sql
What is the difference between local variables and global variables?
how to calculate the difference between two dates? : Sql dba
What is sql select statement?
Oracle (3259)
SQL Server (4518)
MS Access (429)
MySQL (1402)
Postgre (483)
Sybase (267)
DB Architecture (141)
DB Administration (291)
DB Development (113)
SQL PLSQL (3330)
MongoDB (502)
IBM Informix (50)
Neo4j (82)
InfluxDB (0)
Apache CouchDB (44)
Firebird (5)
Database Management (1411)
Databases AllOther (288)