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

What methods do you follow to protect from sql injection attack?

967


Explain in brief about Microsoft SQL server?

1012


What is the minimum recommended amount of ram for sql server 2012 enterprise?

887


What is the recovery model?

931


What are partitioned views and distributed partitioned views?

977


How many types of database relationship in sql server?

994


Differentiate between a primary key and a unique key.

999


What are orphan records?

886


What is partitioned view?

853


What is a view and what are its advantages?

1053


Explain what is scheduled job and how to create it?

898


What is raiseerror? What is raiseerror?

1066


How to check parameter value in stored procedure sql server?

912


Explain logical operators in sql server?

1032


What is cross join in sql server joins?

1074