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 / rajkumar v
select SNo, '(' + convert(varchar,count(SNo)) + ')' from
test group by SNo having COUNT(*)>=1
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What happens when converting big values to integers?
What is the function of inner join?
How to test a dml trigger in ms sql server?
What do you understand by SQL*Net?
What is exporting and importing utility?
Will sql server 2005 allow you to reduce the size of a column?
How to drop an existing user defined function in ms sql server?
Explain what is use of dbcc commands?
How to call a function from a stored procedure in SQL Server ?
How to create a simple table to test triggers in ms sql server?
What is a non-clustered index?
What are the differences between substr and charindex in sql server.
How can a user-defined datatype be created?
What is default port number for sql server 2000?
What is a system database and what is a user database?