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

how to find the second highest salary from emp table?

Answer Posted / barochia dharmesh

select Income from (
select Rank() over(order by Income desc) topRecord, Income
from (select distinct Income from tblName) tbl ) tbl2
where topRecord = 2

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How many functions are there in sql?

1032


how to create a new table by selecting rows from another table in mysql? : Sql dba

1107


How do I view a sql trace file?

1035


How does sql*loader handles newline characters in a record? : aql loader

1047


Can we want to pass a parameter payroll_id to this external pl/sql function, how do we do it?

1067


what are the drivers in mysql? : Sql dba

1025


What is replication id?

941


what is schema? : Sql dba

1051


What is embedded sql in db2?

1022


How do I edit a trigger in sql developer?

1000


What is pl sql variable?

995


What are inner and outer joins examples of both?

965


Is a view faster than a stored procedure?

974


How to revise and re-run the last sql command?

1164


What are sql functions? Describe in brief different types of sql functions?

1104