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 / neeraj
If the column name is key
select key,count(*) from jojo
group by key
simple
| Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
Characterize join and name diverse sorts of joins?
How you can get a list of all the table constraints in a database?
What is sql server profiler trace data file?
How can we solve concurrency problems?
What is the difference between a unique key and primary key?
How many categories of data types used by sql server?
What are the differences between char and varchar in ms sql server?
How many databases Microsoft SQL server provides?
You have modified 100 store procedures and want to replicate these changes from development to prodution, and production can have users using the Server/DB, how would you replicate without causing issues?
How to locate and take substrings with charindex() and substring() functions?
What is attribute hierarchy? : sql server analysis services, ssas
how many layers of tcp/ip protocol combined of? : Sql server database administration
what is the system function to get current user's user id? : Sql server database administration
what are the new features in SSRS?
What is the bookmark lookup and rid lookup?