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...


Find top Nth employee from each department in terms of
salary?

Answers were Sorted based on User's Feedback



Find top Nth employee from each department in terms of salary?..

Answer / khushboo

select top 1 emp_name,emp_sal from employee order by emp_sal
desc

Is This Answer Correct ?    0 Yes 2 No

Find top Nth employee from each department in terms of salary?..

Answer / madhu

select top 1 salary,employee from (table name) group by
department

Is This Answer Correct ?    10 Yes 13 No

Find top Nth employee from each department in terms of salary?..

Answer / suri

select max(m.total_amt),e.emp_name, d.dept_name from
hr_employee_salary_mst m,
hr_employee_mst e, hr_dept_table d
where d.dept_id=e.dept_id
and m.employee_id=e.emp_id
group by d.dept_name,e.emp_name,d.dept_name

Is This Answer Correct ?    3 Yes 7 No

Post New Answer

More SQL Server Interview Questions

2) Consider a Table name A which has below records ID --- 5 5 5 5 5 Consider another table B which has below records ID -- 5 5 5 5 5 5 5 5 How many rows will be returned by each of the below queries a) select * from A inner join B on A.id = b.ID b) select * from A left join B on A.id = b.ID c) select * from A right join B on A.id = b.ID

2 Answers   Synechron, TCS,


Write an sql query to find the names of employees start with ‘a’?

1 Answers  


Explain the advantages of merge replication?

0 Answers  


If a stored procedure is taking a table data type, how it looks?

1 Answers  


what is mean by crystal repoart? ahere we will mainly use that?

1 Answers  


How do I create a stored procedure in dbml?

0 Answers  


Who developed sql server?

0 Answers  


How to integrate the ssrs reports in application?

0 Answers  


When we should use @@error?

0 Answers  


How to recompile stored procedure at run time?

0 Answers  


Can you explain what are commit and rollback in sql?

0 Answers  


Explain cdc and sql injection?

0 Answers  


Categories