Update docs/en/sql-reference/functions/array-functions.md

Co-authored-by: olgarev <56617294+olgarev@users.noreply.github.com>
This commit is contained in:
Roman Bug 2021-08-12 09:44:54 +03:00 committed by GitHub
parent f53ef136b1
commit 54664ed013
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -18,7 +18,7 @@ empty([x])
An array is considered empty if it contains all empty elements. An array is considered empty if it contains all empty elements.
!!! note "Note" !!! note "Note"
Can be optimized by enabling the [optimize_functions_to_subcolumns](../../operations/settings/settings.md#optimize-functions-to-subcolumns) setting. With `optimize_functions_to_subcolumns = 1` the function reads only [size0](../../sql-reference/data-types/array.md#array-size) subcolumn instead of reading and processing the whole array column. The query `SELECT empty(arr) FROM table;` transforms to `SELECT arr.size0 = 0 FROM TABLE;`. Can be optimized by enabling the [optimize_functions_to_subcolumns](../../operations/settings/settings.md#optimize-functions-to-subcolumns) setting. With `optimize_functions_to_subcolumns = 1` the function reads only [size0](../../sql-reference/data-types/array.md#array-size) subcolumn instead of reading and processing the whole array. The query `SELECT empty(arr) FROM table;` transforms to `SELECT arr.size0 = 0 FROM table;`.
The function also works for [strings](string-functions.md#empty) or [UUID](uuid-functions.md#empty). The function also works for [strings](string-functions.md#empty) or [UUID](uuid-functions.md#empty).