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

I Have Employee table having column name as ID,SALARY
how to get second max salary from employee table with id
ex
ID SALARY
1 20000
7 37000
2 5000

Answer Posted / belson gnana pradeep

Select Top 1 salary from (Select TOP 2 salary from tbl_salary order by salary desc)a order by salary

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what is the primary use of the model database? : Sql server administration

1024


Due to some maintenance being done, the sql server on a failover cluster needs to be brought down. How do you bring the sql server down?

1305


How to retrieve error messages using odbc_errormsg()?

1033


Do you know what is recursion? Is it possible for a stored procedure to call itself or recursive stored procedure?

983


Is null vs coalesce?

849


Explain the working of sql privileges?

1069


how can u get last observation in an unknown dataset ?

2422


What do you mean by authentication modes in sql server?

1065


What are the system database in sql server 2008?

1015


Differentiate between mongodb vs. Sql server?

1074


Explain different types of locks in sql server.

1064


Explain having clause?

948


What is openrowset sql server?

1104


What is normalization and denormalization in sql server?

994


Explain log shipping?

997