Red > Green > Refactor > Red

cycle is based on desire

having clause

description(snippet from reference)

The SQL HAVING Clause is used in combination
with the GROUP BY Clause
to restrict the groups of returned rows
to only those whose the condition is TRUE.

reference

SQL: HAVING Clause