mirror of
https://github.com/django/django.git
synced 2025-08-03 02:23:12 +00:00
Fixed #26617 -- Added distinct argument to contrib.postgres's StringAgg.
This commit is contained in:
parent
149ace94df
commit
df8412d2e5
4 changed files with 33 additions and 5 deletions
|
@ -61,7 +61,7 @@ General-purpose aggregation functions
|
|||
``StringAgg``
|
||||
-------------
|
||||
|
||||
.. class:: StringAgg(expression, delimiter)
|
||||
.. class:: StringAgg(expression, delimiter, distinct=False)
|
||||
|
||||
Returns the input values concatenated into a string, separated by
|
||||
the ``delimiter`` string.
|
||||
|
@ -70,6 +70,13 @@ General-purpose aggregation functions
|
|||
|
||||
Required argument. Needs to be a string.
|
||||
|
||||
.. attribute:: distinct
|
||||
|
||||
.. versionadded:: 1.11
|
||||
|
||||
An optional boolean argument that determines if concatenated values
|
||||
will be distinct. Defaults to ``False``.
|
||||
|
||||
Aggregate functions for statistics
|
||||
==================================
|
||||
|
||||
|
|
|
@ -81,7 +81,9 @@ Minor features
|
|||
:mod:`django.contrib.postgres`
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
* ...
|
||||
* The new ``distinct`` argument for
|
||||
:class:`~django.contrib.postgres.aggregates.StringAgg` determines if
|
||||
concatenated values will be distinct.
|
||||
|
||||
:mod:`django.contrib.redirects`
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue