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 / hitesh kumar vyas s
Take a example as to find the same student who got first and
second marks in each of sub.
SELECT RollNo,COUNT(Rank) FROM Student GROUP BY RollNo,rank
ORDER BY rank
Is This Answer Correct ? | 6 Yes | 1 No |
Post New Answer View All Answers
What is the difference between DataRow.Delete() and DataRow.Remove()?
Please differentiate between a local and a global temporary table?
How to drop an existing table?
How to connect a database with sql express.?
How to generate create table script on an existing table in ms sql server?
What stored by the tempdb ? : sql server database administration
How much is a sql server license?
Does group by sort data?
What is inner join? Explain with an example?
what is a self join? Explain it with an example? : Sql server database administration
What are sub reports and how to create them?
What is the difference between cartesian product and cross join?
Are connections to sql server encrypted?
How to Improve the performencs of SQL Server 2005 exclude stored Procedure and Indexes?
Explain what are partitioned views and distributed partitioned views?