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 find second highest salary of an employee.

Answer Posted / oboyah

SELECT e1.* from ( SELECT last_name, salary,
DENSE_RANK() OVER ( ORDER BY salary DESC) rank
FROM employees) e1 where e1.Rank = 2;

Is This Answer Correct ?    0 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what is foreign key? : Sql dba

1107


How do I filter in sql profiler?

1055


what is 'mysqlimport'? : Sql dba

1111


Why stored procedures are faster than query?

1079


What is insert command in sql?

1192


what are set operators in sql? : Sql dba

1108


Mention what does plv msg allows you to do?

1164


what is a primary key? : Sql dba

1086


Why indexing is needed?

1044


Why do we use subquery?

1076


What is mdf ldf and ndf?

1057


What is sqlca in db2?

1036


how do you login to mysql using unix shell? : Sql dba

1129


How do I start sql profiler?

1048


Why is there a need for sqlcode and sqlerrm variables?

1104