Concept:
In SQL, aggregate functions such as:
- \texttt{SUM()}
- \texttt{COUNT()}
- \texttt{AVG()}
- \texttt{MAX()}
- \texttt{MIN()}
are used to perform calculations on a set of rows and return a single result.
To filter results based on aggregate values, SQL uses the HAVING clause.
Step 1: Understand the WHERE clause.
The WHERE clause filters rows before grouping takes place.
Example:
\[
\texttt{SELECT * FROM Employees WHERE Salary>50000;}
\]
It cannot be used with aggregate functions directly.
Step 2: Understand the HAVING clause.
The HAVING clause is used to filter results after aggregation.
Example:
\[
\texttt{SELECT Department, COUNT(*)}
\]
\[
\texttt{FROM Employees}
\]
\[
\texttt{GROUP BY Department}
\]
\[
\texttt{HAVING COUNT(*)>5;}
\]
This query returns only those departments having more than 5 employees.
Step 3: Conclusion.
Since filtering conditions applied to aggregate functions are handled using the HAVING clause, the correct answer is:
\[
\text{HAVING}
\]