Name Salary
Abc 50000
Abc 50000
xyz 20000
find the max salary using aggregate function?

Answers were Sorted based on User's Feedback



Name Salary Abc 50000 Abc 50000 xyz 20000 find the max salary using aggregate ..

Answer / guest

select max(sal) from tab_name;
or
select * from tab_name where sal=(select max(sal) from
tab_name) and rownum<=1;

Is This Answer Correct ?    19 Yes 0 No

Name Salary Abc 50000 Abc 50000 xyz 20000 find the max salary using aggregate ..

Answer / prashant

select max(salary) from
(select distinct(salary) from ABC)

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More SQL PLSQL Interview Questions

Can we write dml inside a function in sql server?

0 Answers  


What is cursor and why it is required?

0 Answers  


Is sqlexception checked or unchecked?

0 Answers  


How do I view an execution plan in sql?

0 Answers  


What is aggregate function in sql?

0 Answers  






What is difference between procedure and trigger?

0 Answers  


What are the return values of functions SQLCODE and SQLERRM ?

2 Answers   PreVator,


What are character functions in sql?

0 Answers  


Enlist some predefined exceptions?

0 Answers  


What is the maximum number of triggers, you can apply on a single table?

0 Answers  


What is the difference between CHAR and VARCHAR2? If VARCHAR2 serves the uses of CHAR why CHAR is still used and not been discarded yet?

9 Answers   Oracle,


What are the types of operators available in sql?

0 Answers  


Categories