ClickHouse/docs/ru/data_types/special_data_types/nothing.md

18 lines
1.0 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.

# Nothing {#nothing}
Этот тип данных предназначен только для того, чтобы представлять [NULL](../../query_language/syntax.md), т.е. отсутствие значения.
Невозможно создать значение типа `Nothing`, поэтому он используется там, где значение не подразумевается. Например, `NULL` записывается как `Nullable(Nothing)` ([Nullable](../../data_types/nullable.md) — это тип данных, позволяющий хранить `NULL` в таблицах). Также тип `Nothing` используется для обозначения пустых массивов:
``` sql
SELECT toTypeName(Array())
```
``` text
┌─toTypeName(array())─┐
│ Array(Nothing) │
└─────────────────────┘
```
[Оригинальная статья](https://clickhouse.tech/docs/ru/data_types/special_data_types/nothing/) <!--hide-->