mirror of
https://github.com/django/django.git
synced 2025-08-03 02:23:12 +00:00
Fixed #26327 -- Added JsonAgg to contrib.postgres.
Thanks Tim Graham for review.
This commit is contained in:
parent
52188a5ca6
commit
0a26f3c338
4 changed files with 46 additions and 6 deletions
|
@ -58,6 +58,15 @@ General-purpose aggregation functions
|
|||
Returns ``True`` if at least one input value is true, ``None`` if all
|
||||
values are null or if there are no values, otherwise ``False``.
|
||||
|
||||
``JsonAgg``
|
||||
-----------
|
||||
|
||||
.. class:: JsonAgg(expressions, **extra)
|
||||
|
||||
.. versionadded:: 1.11
|
||||
|
||||
Returns the input values as a ``JSON`` array.
|
||||
|
||||
``StringAgg``
|
||||
-------------
|
||||
|
||||
|
|
|
@ -172,6 +172,9 @@ Minor features
|
|||
operation allow using PostgreSQL's ``citext`` extension for case-insensitive
|
||||
lookups.
|
||||
|
||||
* The new :class:`~django.contrib.postgres.aggregates.JsonAgg` allows
|
||||
aggregating values as a JSON array.
|
||||
|
||||
:mod:`django.contrib.redirects`
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue