Question · SQL and MySQL course · Module 6: Aggregation and grouping

COUNT(*) versus COUNT(column)

How does COUNT(*) differ from COUNT(data_zwrotu)?

Answer options

  • There is no difference - both count the same way
  • COUNT(*) skips NULL values, while COUNT(column) counts everything
  • COUNT(*) counts all rows, while COUNT(data_zwrotu) skips rows with a NULL value in that column
  • COUNT(data_zwrotu) counts columns, not rows

You can check the correct answer by solving this task in the CodeWorlds game.