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

can any one answer this query,thank you in advance

Table 1 has 2 columns: EmployeeId, T shirtsize(values can
be 1,2,3)
Table 2 has 2 columns: EmployeeId, Region
Write SQL to Find the region which has the largest number
of people with Tshirt size=3

Answer Posted / avaneesh bajoria

select top 1 t2.region , count(t1.tsize) as co from tsize
t1,region t2
where t1.empid = t2.empid
group by t2.region,t1.tsize
having t1.tsize = 3 order by co desc

Is This Answer Correct ?    4 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the partitioning method?

1025


What are sql dirty pages?

1031


Do you know how to store and query spatial data?

1044


Do you know how to make remote connection in database?

969


What is table value parameters (tvp)?

1107


Where actually sql azure database is hosted?

163


Explain the concept of view and Types of views in SQL server?

995


What are some of the pros and cons of not dropping the sql server builtinadministrators group? : sql server security

990


Define a cross join?

1041


Explain tables in SQL Azure?

120


Why should you use or avoid select * statements?

1033


What is 2nf example?

1001


what are the types of indexes? : Sql server database administration

1129


Explain “row_number()” in sql server with an example?

1011


how you can list all the tables in a database?

1030