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 / javamaster

select key,count(key) from tablename
group by key order by key

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Does index speed up select statements?

1010


How to call a function from a stored procedure in SQL Server ?

1021


Why we need sql server?

956


Explain syntax for dropping triggers?

925


While using a cursor, how can you differentiate between a deleted row and a row that has been inserted with null data values?

1038


How to Check if table exists in sql server?

1126


Can we use having clause without group by?

975


What is trace flag in sql server?

1016


What is a heap?

1029


Determine when an index is appropriate?

1070


How to list all columns in a table using odbc_columns()?

972


What is a mixed extent?

1007


Why do we backup Active Directory ?

1036


Explain primary key?

951


How to create prepared statements using odbc_prepare()?

1059