Advertisements
Advertisements
Question
What is the purpose of the following clauses in a select statement?
HAVING
Short Answer
Advertisements
Solution
In an SQL select statement, the HAVING clause is used to filter groups of rows created by the GROUP BY clause.
It acts just like a WHERE clause, but with one critical difference: WHERE filters individual rows before grouping, while HAVING filters aggregate groups after grouping.
shaalaa.com
Is there an error in this question or solution?
Chapter 1: Querying and SQL Functions - Exercise [Page 23]
