Machine-translated by Google. Questions are authored in English.
Top

Discussion

COUNT(field_name) tallies only those rows that contain a value; it ignores all null values.

  • A.True
  • B.False

Answer: A

Correct answer: True

COUNT(field_name) counts rows in which that field is not null, so nulls reduce the count.

COUNT(*) behaves differently, counting rows regardless of their contents, and the gap between the two is a quick way to find how many nulls a column holds. The same null-skipping applies to SUM, AVG, MIN and MAX, which matters most for AVG: it divides by the number of non-null values, not by the number of rows.

No comment is present. Be the first to comment.
Loading…

Post your comment

Please log in or register to post a comment.