Difference between a Where Clause and a Having Clause
Having Clause is basically used only with the GROUP BY function in a query.
WHERE Clause is applied to each row before they are part of the GROUP BY function in a query.
Syntax
Having Clause:
SELECT column_name, aggregate_function(column_name)
FROM table_name
WHERE column_name operator value
GROUP BY column_name
HAVING aggregate_function(column_name) operator value
Where Clause
SELECT column_name(s)
FROM table_name
WHERE column_name operator value
Liked By
Write Answer
What is the difference between a "where" clause and a "having" clause?
Join MindStick Community
You have need login or register for voting of answers or question.
Amit Singh
30-Oct-2010