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 / sagar more
select replace(wm_concat(key||''||'('||count(*)||')' ),',','') key from drop1
group by key
| Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
Explain the cursor lock types?
How do I find sql server instance name?
What is difference between rollback immediate and with no_wait during alter database?
How to create an identity column?
Explain transaction server auto commit?
What information is maintained within the msdb database?
Explain relational data?
Do you know nested transaction?
Why should one not prefix user stored procedures with ‘sp_’?
How many types of stored procedures are there in sql server?
How to grant a permission in ms sql server using "grant execute" statements?
What type of locking occurs during the snapshot generation? : sql server replication
If you want to send some data from access database to sql server database. What are different component of ssis will you use?
What are relationships and mention different types of relationships in the dbms
How to recreate an existing index in ms sql server?