ClickHouse/docs/tr/sql-reference/aggregate-functions/index.md
Ivan Blinkov d91c97d15d
[docs] replace underscores with hyphens (#10606)
* Replace underscores with hyphens

* remove temporary code

* fix style check

* fix collapse
2020-04-30 21:19:18 +03:00

63 lines
1.7 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

---
machine_translated: true
machine_translated_rev: e8cd92bba3269f47787db090899f7c242adf7818
toc_folder_title: "Toplama Fonksiyonlar\u0131"
toc_priority: 33
toc_title: "Giri\u015F"
---
# Toplama fonksiyonları {#aggregate-functions}
Toplama fonksiyonları [normal](http://www.sql-tutorial.com/sql-aggregate-functions-sql-tutorial) veritabanı uzmanları tarafından beklendiği gibi.
ClickHouse da destekler:
- [Parametrik agrega fonksiyonları](parametric-functions.md#aggregate_functions_parametric), sütunlara ek olarak diğer parametreleri kabul eder.
- [Birleştiriciler](combinators.md#aggregate_functions_combinators) toplama işlevlerinin davranışını değiştiren.
## NULL işleme {#null-processing}
Toplama sırasında, tüm `NULL`s atlanır.
**Örnekler:**
Bu tabloyu düşünün:
``` text
┌─x─┬────y─┐
│ 1 │ 2 │
│ 2 │ ᴺᵁᴸᴸ │
│ 3 │ 2 │
│ 3 │ 3 │
│ 3 │ ᴺᵁᴸᴸ │
└───┴──────┘
```
Diyelim ki değerleri toplamanız gerekiyor `y` sütun:
``` sql
SELECT sum(y) FROM t_null_big
```
┌─sum(y)─┐
│ 7 │
└────────┘
Bu `sum` fonksiyon yorumlar `NULL` olarak `0`. Özellikle, bu, işlevin tüm değerlerin bulunduğu bir seçimin girişini aldığı anlamına gelir `NULL`, sonra sonuç olacak `0`, değil `NULL`.
Şimdi kullanabilirsiniz `groupArray` bir dizi oluşturmak için işlev `y` sütun:
``` sql
SELECT groupArray(y) FROM t_null_big
```
``` text
┌─groupArray(y)─┐
│ [2,2,3] │
└───────────────┘
```
`groupArray` içermez `NULL` elde edilen dizi.
[Orijinal makale](https://clickhouse.tech/docs/en/query_language/agg_functions/) <!--hide-->