This is an automated email from the ASF dual-hosted git repository.
alamb pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/datafusion.git
The following commit(s) were added to refs/heads/main by this push:
new 1b3a7af673 Fix count() docs around including null values (#11293)
1b3a7af673 is described below
commit 1b3a7af673e5b590da94cea74892ee2c0c097848
Author: Piotr Findeisen <[email protected]>
AuthorDate: Sat Jul 6 13:08:58 2024 +0200
Fix count() docs around including null values (#11293)
The count aggregate was documented to count null values, but it does not
do that. The implemented behavior is correct, so let's fix docs.
---
docs/source/user-guide/sql/aggregate_functions.md | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/docs/source/user-guide/sql/aggregate_functions.md
b/docs/source/user-guide/sql/aggregate_functions.md
index 427a7bf130..edb0e1d0c9 100644
--- a/docs/source/user-guide/sql/aggregate_functions.md
+++ b/docs/source/user-guide/sql/aggregate_functions.md
@@ -123,11 +123,9 @@ bool_or(expression)
### `count`
-Returns the number of rows in the specified column.
+Returns the number of non-null values in the specified column.
-Count includes _null_ values in the total count.
-To exclude _null_ values from the total count, include `<column> IS NOT NULL`
-in the `WHERE` clause.
+To include _null_ values in the total count, use `count(*)`.
```
count(expression)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]