Which aggregate function returns the number of rows matching a condition?

SQL Fundamentals Easy

SQL Fundamentals — Easy

Which aggregate function returns the number of rows matching a condition?

Key points

  • COUNT() is used to count the number of rows
  • SUM() calculates the total of a numeric column
  • TOTAL() is not a valid SQL function
  • NUM() is not a recognized aggregate function

Ready to go further?

Related questions