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 a table with 3 columns country,empname,salary and i want the query for get the  name of the employees who is getting top 2 nd highest salary for individual country?
Thanks in advance 

Answer Posted / madhu

select * from ( select country,empname,salary, dense_rank() over (partition by country order by salary) rank from emp) where rank <= 2;

Is This Answer Correct ?    4 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

We can use a calculated field to dynamically create the burst recipients in Cognos 8. Can we do the same in Cognos ReportNet 1.1?

2566


i have taken quantity on ANx-axis & months on y-axis(months r not in oreder )when i run the reoprt i need months in proper order .how can i do this ?

2050


Can you define set to be cardinality?

1063


WHAT IS METRIC STUDIO?WHAT IS SCORE CARDS HOW TO IMPLEMENT IT AND WHAT IS THE USE OF SCORE CARD?

6980


Give me any example of semi and non additive measures?

1032


What is defined as data mining?

1079


What is model filter?

1320


What is the difference between the standard and metrics folder?

1021


4. How many dimensions did you use in your reports?

1998


-------------What is Coditional Prompting?

2224


What is difference between page break and section report?

1259


How do we convert from Numeric to be Words?

3098


How do you call a store procedure within a transformation?

1053


Can you define cognos impromptu?

1079


What is cognos powerhouse?

1082