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

if we have a column (Key) in a table.
and values of that column is
Key
1
1
1
2
2
3
3
4
4
5
5
5
and we want to show the data after query..like..

1(3)
2(3)
3(2)
4(2)
5(3)
how many times a single term comes..

Answer Posted / vikas kant

select key,count(key1) from [table_name]
group by key

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which autogrowth database setting is good?

1059


What command is used to delete a table from the database in the sql server and how?

1113


Where actually sql azure database is hosted?

163


What are pages and extents? : SQL Server Architecture

1017


Explain partitioned view?

1076


What are different types of statement?

1017


Explain primary key, foreign key and unique key?

993


What is forward - only cursors / read only cursor?

1089


What is an execution plan? When would you use it?

979


How do you send email on SQL Server?

1064


Determine when to use stored procedure to complete sql server tasks?

1054


How do I edit a procedure in sql server?

957


Explain few of the new features of sql server 2008 management studio

920


Once setting replication, can you have distributor on sql server 2005, publisher of sql server 2008?

951


What are rest-style architecture's?

170