Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Query for second maximum salary in each in each department

Answer Posted / swaraj

Select Department,Max(Salary)
From (Select E1.Department,E1.Salary
From Employee E1,(Select Department,Max(Salary) as Salary
From Employee group by Department) E2
Where E1.Department = E2.Department
And E1.Salary<E2.Salary) E
Group by Department

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between local and global temporary table?

1047


What are the different sql languages?

1036


what is the difference between undefined value and null value? : Sql dba

1101


How do I clear the screen in sql plus?

1042


Is sql a case sensitive language?

947


Where are my tempfiles, I don't see them in v$datafile or dba_data_file?

1000


What is embedded sql what are its advantages?

1043


How can we implement rollback or commit statement in a trigger?

1039


What is pl sql commands?

1046


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

998


How can we store rows in PL/SQL using array?

1220


Is grant a ddl statement?

897


what are the security recommendations while using mysql? : Sql dba

1119


what is rollback? : Sql dba

1112


What is meant by truncate in sql?

1068