Table E:
Name dept month sal
1 A JAN 800
2 B APR 1000
3 A JAN 300
4 A JAN 600
5 C JUN 400


1) SELECT HIGHEST SAL PAID DEPT IN JAN MONTH?
2) WRITE QUERY GET MAX SAL DEPT NO?

Answer Posted / venkateswara reddy

1)select dept from E where sal=(select max(sal) from E where
month='JAN')
2)select dept from E where sal=(select max(sal) from E)

Is This Answer Correct ?    0 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

List out the difference between commit, rollback, and savepoint?

616


what are archived logs?

1712


How to drop an index?

539


How much memory your 10g xe server is using?

578


What is a data lock in oracle?

606






Whether any commands are used for months calculation? If so, what are they?

592


WHEN CURSOR MOVES FROM ONE FORM TO ANOTHER FORM, HOW MANY TRIGGER WILL BE FIRED AND WHAT ARE THEIR SEQUENCE?

1798


Give the advantages and disadvantages of clusters.

570


What is the sql query to concatenate column values from multiple rows in oracle?

557


Difference between pre-select and pre-query

573


How to create an oracle database?

576


What are the different types of modules in oracle forms?

552


How to turn on or off recycle bin for the instance?

605


What are the differences between date and timestamp in oracle?

549


How to assign values to data fields in record variables?

578