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 / sandeep

select top(1) a.salary
from

(
select top(2)sal
from
employee
order by salary desc
)a
order by a.salary asc

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 sql indexing?

965


What is a database trigger?

1019


What is lexical units in pl sql?

1055


What is int identity in sql?

1064


What does bitemporal mean?

1010


What is sequence in sql?

945


How can use stored procedures in sql?

1083


What is a pragma statement?

1204


what is the difference between mysql_fetch_object and mysql_fetch_array? : Sql dba

989


How do you exit in sql?

1065


What is difference between stored procedure and trigger?

1061


Suppose a student column has two columns, name and marks. How to get name and marks of the top three students.

956


How to change a value of the field ‘salary’ as 7500 for an employee_name ‘john’ in a table employee_details?

1384


What company owns postgresql?

963


Explain the purpose of %type and %rowtype data types?

876