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

consider a table which contain 4 columns,ename,eno,sal and
deptno, from this table i want to know ename who having
maximum salary in deptno 10 and 20.

Answer Posted / sp

select top 2 ename, salary, dept from dbo.employee where
dept in(10,20) order by salary desc

Is This Answer Correct ?    1 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

explain advantages of innodb over myisam. : Sql dba

1115


What is difference between primary and secondary key?

1010


If i can use sys.check_constraints to display my constraints from my database using sql server 2005, how can i display then if i am using sql server 2000????

3991


Can I learn sql in a week?

1047


What is flag in sql?

1019


What is the maximum number of rows in sql table?

1010


What is the difference between numeric and autonumber?

983


What do you understand by case manipulation functions?

1018


Why do we need sharding?

979


Are stored procedures compiled?

903


What is varchar used for?

1070


What are pl/sql packages?

1087


Is sql between inclusive?

1111


What does cursor do in sql?

1005


what are aggregate and scalar functions? : Sql dba

1043