diff options
| author | Mariusz Felisiak <felisiak.mariusz@gmail.com> | 2023-11-27 11:49:24 +0100 |
|---|---|---|
| committer | Mariusz Felisiak <felisiak.mariusz@gmail.com> | 2023-11-27 11:57:07 +0100 |
| commit | a652f0759651dd7103ed04336ef85dc410f680c1 (patch) | |
| tree | 2045ed00c950561e7944849020f9afce1c6b8522 /docs | |
| parent | 9baaf89eed42f9e747c774bc79543f47ea9697f8 (diff) | |
Fixed #34978, Refs #31331 -- Added backward incompatibility note about raw aggregations on MySQL.
Thanks Matthew Somerville for the report.
Diffstat (limited to 'docs')
| -rw-r--r-- | docs/releases/4.2.txt | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/docs/releases/4.2.txt b/docs/releases/4.2.txt index b23b4a4ff9..37cf228dc7 100644 --- a/docs/releases/4.2.txt +++ b/docs/releases/4.2.txt @@ -409,6 +409,16 @@ fields modified in the custom ``save()`` methods should be added to the ``update_fields`` keyword argument before calling ``super()``. See :ref:`overriding-model-methods` for more details. +Dropped support for raw aggregations on MySQL +--------------------------------------------- + +MySQL 8+ allows functional dependencies on ``GROUP BY`` columns, so the +pre-Django 4.2 workaround of grouping by primary keys of the main table is +removed. As a consequence, using ``RawSQL()`` aggregations is no longer +supported on MySQL as there is no way to determine if such aggregations are +needed or valid in the ``GROUP BY`` clause. Use :ref:`aggregation-functions` +instead. + Miscellaneous ------------- |
