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 / bennison terry

Select Top 1 * from Tbl_Salary where ID not in (Select top 1 ID from tbl_salary order by salary desc) order by Id desc

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 a view and a stored procedure?

985


What is linked report?

121


What do you mean by cardinality?

849


Is it possible to import data directly from t-sql commands without using sql server integration services? If so, what are the commands?

1325


What are scalar functions?

949


Which table keeps information about stored procedures?

892


Would you store your query in a ssrs report or a database server? State the reason why?

148


What is analysis service repository?

969


Give the query of getting last two records from the table in SQL SERVER?

901


What are the differences between ms sql server & oracle?

995


List some of the rules that apply to creating and using a ‘view’

818


How to download and install microsoft sql server management studio express?

977


Does group by or order by come first?

901


What is the fastest way to permanently delete a 1 million row table named customers?

1156


What is the fillfactor concept in indexes?

935