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...

Write a query to get 2nd maximum salary in an employee table ?

Answer Posted / tejasvita dhuri

select id,salary from (select id,salary,ROW_NUMBER()over (order by salary desc) as rowcol from emp)A
where A.rowcol=2

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 compiled query?

1046


What is an intersect?

1112


What is a primary key called that is made up of more than one field?

1357


Is vs as in pl sql?

996


How do you declare a variable in pl sql?

1035


explain the difference between myisam static and myisam dynamic. : Sql dba

956


Is sql free?

981


What is the difference between count 1 and count (*) in a sql query?

1004


Show how functions and procedures are called in a pl/sql block.

1139


Is t sql a programming language?

1074


Can we use view in stored procedure?

910


What does pl sql developer do?

940


What does the hierarchical profiler does?

1073


How do I view an execution plan in sql?

995


How do you optimize a query?

1016