summaryrefslogtreecommitdiff
path: root/docs/ref
diff options
context:
space:
mode:
authorMariusz Felisiak <felisiak.mariusz@gmail.com>2026-04-18 08:53:21 +0200
committerGitHub <noreply@github.com>2026-04-18 08:53:21 +0200
commited79c5959add54b6e8ea589ec601e0d2e801517e (patch)
tree0d00f241bea6de88203d1314c7de92cb262b3a3f /docs/ref
parentd687d412a9abd9c80e31945f16ce32c020512394 (diff)
Fixed #37028 -- Added BitAnd(), BitOr(), and BitXor() aggregates.
Diffstat (limited to 'docs/ref')
-rw-r--r--docs/ref/contrib/postgres/aggregates.txt15
-rw-r--r--docs/ref/models/querysets.txt36
2 files changed, 51 insertions, 0 deletions
diff --git a/docs/ref/contrib/postgres/aggregates.txt b/docs/ref/contrib/postgres/aggregates.txt
index 040e57c5af..6381f0f7eb 100644
--- a/docs/ref/contrib/postgres/aggregates.txt
+++ b/docs/ref/contrib/postgres/aggregates.txt
@@ -62,6 +62,11 @@ General-purpose aggregation functions
Returns an ``int`` of the bitwise ``AND`` of all non-null input values, or
``default`` if all values are null.
+ .. deprecated:: 6.1
+
+ This class is deprecated in favor of the generally available
+ :class:`~django.db.models.BitAnd` class.
+
``BitOr``
---------
@@ -70,6 +75,11 @@ General-purpose aggregation functions
Returns an ``int`` of the bitwise ``OR`` of all non-null input values, or
``default`` if all values are null.
+ .. deprecated:: 6.1
+
+ This class is deprecated in favor of the generally available
+ :class:`~django.db.models.BitOr` class.
+
``BitXor``
----------
@@ -78,6 +88,11 @@ General-purpose aggregation functions
Returns an ``int`` of the bitwise ``XOR`` of all non-null input values, or
``default`` if all values are null.
+ .. deprecated:: 6.1
+
+ This class is deprecated in favor of the generally available
+ :class:`~django.db.models.BitXor` class.
+
``BoolAnd``
-----------
diff --git a/docs/ref/models/querysets.txt b/docs/ref/models/querysets.txt
index 6a76fc2703..ee401a569d 100644
--- a/docs/ref/models/querysets.txt
+++ b/docs/ref/models/querysets.txt
@@ -4085,6 +4085,42 @@ by the aggregate.
unique values. This is the SQL equivalent of ``AVG(DISTINCT <field>)``.
The default value is ``False``.
+``BitAnd``
+~~~~~~~~~~
+
+.. class:: BitAnd(expression, filter=None, default=None, **extra)
+
+ .. versionadded:: 6.1
+
+ Returns an ``int`` of the bitwise ``AND`` of all non-null input values, or
+ ``default`` if all values are null.
+
+ The ``default`` parameter is not supported on MariaDB, MySQL, and Oracle.
+
+``BitOr``
+~~~~~~~~~
+
+.. class:: BitOr(expression, filter=None, default=None, **extra)
+
+ .. versionadded:: 6.1
+
+ Returns an ``int`` of the bitwise ``OR`` of all non-null input values, or
+ ``default`` if all values are null.
+
+ The ``default`` parameter is not supported on MariaDB, MySQL, and Oracle.
+
+``BitXor``
+~~~~~~~~~~
+
+.. class:: BitXor(expression, filter=None, default=None, **extra)
+
+ .. versionadded:: 6.1
+
+ Returns an ``int`` of the bitwise ``XOR`` of all non-null input values, or
+ ``default`` if all values are null.
+
+ The ``default`` parameter is not supported on MariaDB, MySQL, and Oracle.
+
``Count``
~~~~~~~~~