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
What is data source view or dsv? : sql server analysis services, ssas
Explain nested stored procedure. Syntax and an example for create nested stored procedure?
What is merge?
How do I manually uninstall an instance of sql server 2016?
How to list all stored procedures in the current database using ms sql server?
You want to check the syntax of a complicated update sql statement without executing it. What command should you use?
Explain about the command-line tool SQLCMD?
What is data compression?
What are synonyms?
What is difference between rownum and rowid?
Explain the steps needed to create a scheduled job?
What is t-sql script to take database offline – take database online.
Explain what is use of dbcc commands?
What is bookmark link in ssrs?
How many primary keys are possible in a table?