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 select name from one table which has
id,name and salary from another table which has id, sal
where the salary is the second maximum

Answer Posted / nagendra kumar m r

select top 1 e.[id],e.[name],s.salary from emp e join
emp_sal s on e.[id] = s.[id] and e.[id] in (select top 2
[id] from emp_sal order by salary desc)

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is odbc an api?

1041


What is the JDBC?

1086


What do you mean by odbc?

1027


What is correlated subquery?

2330


Is jdbc connection secure?

957


How do you determine the sensitivity of the ResultSet object?

994


Why is jdbc used?

945


What is the function of drivermanager class?

1103


Is it possible to connect to multiple databases simultaneously?

1069


How to update a resultset programmatically?

1085


How do I find jdbc version?

1007


What is java soft framework?

1007


Give steps to connect to the db using jdbc?

1017


What are the different types of lockings in jdbc?

927


What are the benefits of PreparedStatement over Statement?

1011