What is the difference between the WHERE and HAVING clauses

When GROUP BY is not used, the WHERE and HAVING clauses are essentially equivalent. However, when GROUP BY is used:

  • The WHERE clause is used to filter records from a result.
  • The HAVING clause is used to filter values from a group.

results matching ""

    No results matching ""