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 / elumalai.k

select id,max(salary)from employee where salary<(select
max(salary)from employee)

Is This Answer Correct ?    15 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a bit datatype?

1021


What are the different authentication modes in sql server? How can it be changed?

1139


Why people hate cursor?

1202


Give a example to search fr a string in all stored procedure in sql server.

1063


Explain differences between web edition and business edition?

119


Explain about system database?

1110


Define outer join?

1047


Explain the truncate command?

1037


What the different components of Replication and what is their use?

1125


To which devices can a backup be created and where should these devices be located? : sql server management studio

1102


What do you understand by the data quality services in sql server?

981


Difference between Logical Page and Physical Page in SSRS.

491


What are subqueries in sql server?

1192


What is a transact-sql statement?

1129


What is 2nf normalization form?

1200