mirror of https://github.com/ByConity/ByConity
Add docs. [#CLICKHOUSE-3084]
This commit is contained in:
parent
870b1aefcb
commit
ceaac43707
|
@ -87,11 +87,14 @@ You should use the ``uniqExact`` function if you definitely need an exact result
|
|||
|
||||
The ``uniqExact`` function uses more memory than the ``uniq`` function, because the size of the state has unbounded growth as the number of different values increases.
|
||||
|
||||
groupArray(x)
|
||||
-------------
|
||||
groupArray(x), groupArray(max_size)(x)
|
||||
--------------------------------------
|
||||
Creates an array of argument values.
|
||||
Values can be added to the array in any (indeterminate) order.
|
||||
|
||||
The second version (with ``max_size`` parameter) limits the size of resulting array to ``max_size`` elements.
|
||||
For example, ``groupArray(1)(x)`` is equivalent to ``[any(x)]``.
|
||||
|
||||
In some cases, you can rely on the order of execution. This applies to cases when ``SELECT`` comes from a subquery that uses ``ORDER BY``.
|
||||
|
||||
groupUniqArray(x)
|
||||
|
|
|
@ -86,11 +86,14 @@ uniqExact(x)
|
|||
|
||||
Функция ``uniqExact`` расходует больше оперативки, чем функция ``uniq``, так как размер состояния неограниченно растёт по мере роста количества различных значений.
|
||||
|
||||
groupArray(x)
|
||||
-------------
|
||||
groupArray(x), groupArray(max_size)(x)
|
||||
--------------------------------------
|
||||
Составляет массив из значений аргумента.
|
||||
Значения в массив могут быть добавлены в любом (недетерминированном) порядке.
|
||||
|
||||
Вторая версия (с параметром ``max_size``) ограничивает размер результирующего массива ``max_size`` элементами.
|
||||
Например, ``groupArray(1)(x)`` эквивалентно ``[any(x)]``.
|
||||
|
||||
В некоторых случаях, вы всё же можете рассчитывать на порядок выполнения запроса. Это — случаи, когда ``SELECT`` идёт из подзапроса, в котором используется ``ORDER BY``.
|
||||
|
||||
groupUniqArray(x)
|
||||
|
|
Loading…
Reference in New Issue