DOCAPI-7431: Queries with parameters docs. EN review. RU translation.#6632
Merged
BayoNet merged 6 commits intoClickHouse:masterfrom Aug 27, 2019
Merged
Conversation
blinkov
suggested changes
Aug 23, 2019
| ``` | ||
|
|
||
| #### Syntax of a Query {#cli-queries-with-parameters-syntax} | ||
| #### Query Syntax {#cli-queries-with-parameters-syntax} |
docs/en/interfaces/cli.md
Outdated
| #### Query Syntax {#cli-queries-with-parameters-syntax} | ||
|
|
||
| Format a query by the standard method. Values that you want to put into the query from the app parameters place in braces and format as follows: | ||
| Format a query using the standard method. Place the values that you want to pass from the app parameters to the query in braces in the following format: |
Contributor
There was a problem hiding this comment.
what does "standard method" mean? this syntax has nothing to do with SQL standard
docs/en/interfaces/cli.md
Outdated
|
|
||
| - `name` — Identifier of a placeholder that should be used in app parameter as `--param_name = value`. | ||
| - `data type` — A data type of app parameter value. For example, data structure like `(integer, ('string', integer))` can have a data type `Tuple(UInt8, Tuple(String, UInt8))` (also you can use another [integer](../data_types/int_uint.md) types). | ||
| - `name` — Placeholder identifier that should be used in app parameters as `--param_<name> = value`. |
Contributor
There was a problem hiding this comment.
--param_... example is for console client only
docs/en/interfaces/cli.md
Outdated
| - `name` — Identifier of a placeholder that should be used in app parameter as `--param_name = value`. | ||
| - `data type` — A data type of app parameter value. For example, data structure like `(integer, ('string', integer))` can have a data type `Tuple(UInt8, Tuple(String, UInt8))` (also you can use another [integer](../data_types/int_uint.md) types). | ||
| - `name` — Placeholder identifier that should be used in app parameters as `--param_<name> = value`. | ||
| - `data type` — Data type of the app parameter value. For example, a data structure like `(integer, ('string', integer))` can have the `Tuple(UInt8, Tuple(String, UInt8))` data type (you can also use another [integer](../data_types/int_uint.md) types). |
Contributor
There was a problem hiding this comment.
maybe link to list of available data types?
docs/ru/interfaces/cli.md
Outdated
|
|
||
| ### Запросы с параметрами {#cli-queries-with-parameters} | ||
|
|
||
| Вы можете создать запрос с параметрами и передать в них значения соответствующих параметров клиентского приложения. Например: |
| clickhouse-client --param_parName="[1, 2]" -q "SELECT * FROM table WHERE a = {parName:Array(UInt16)}" | ||
| ``` | ||
|
|
||
| #### Cинтаксис запроса {#cli-queries-with-parameters-syntax} |
|
|
||
| Параметры командной строки переопределяют значения по умолчанию и параметры конфигурационных файлов. | ||
|
|
||
| - Конфигурационных файлов. |
Contributor
There was a problem hiding this comment.
кстати, где-то в этих краях не стоит упомянуть, что начинающееся на param_ интерпретируется как параметры?
Contributor
Author
There was a problem hiding this comment.
Добавил в список параметров.
Co-Authored-By: Ivan Blinkov <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I hereby agree to the terms of the CLA available at: https://yandex.ru/legal/cla/?lang=en
Category (leave one):