Database - Introduction to SQL - Discussion

Discussion Forum : Introduction to SQL - General Questions (Q.No. 27)
27.
To sort the results of a query use:
SORT BY.
GROUP BY.
ORDER BY.
None of the above is correct.
Answer: Option
Explanation:
No answer description is available. Let's discuss.
Discussion:
2 comments Page 1 of 1.

Shubham said:   8 years ago
GROUP BY in SQL is used to apply conditions on the columns.

For example, if you want to find the numbers of Names which are occurring more than 100 times in a Name column of the Student table, then condition must be applied on the column.

i.e.
SELECT ID, Name
FROM Student
GROUP BY (Name)
HAVING count(Name) >= 100;

Rabindra said:   8 years ago
Why we use GROUP BY in SQL?

Describe in detail.

Post your comments here:

Your comments will be displayed after verification.