What is the purpose of the FILTER clause in SQL aggregate functions?

SQL Hard
Select the correct answer: Single Choice

Key points

  • FILTER clause enables per-aggregate filtering
  • Useful for applying different conditions to different aggregates
  • Eliminates the need for subqueries for filtering aggregates

Ready to go further?