Allow multiple --query parameters in clickhouse-client/local.#54249
Allow multiple --query parameters in clickhouse-client/local.#54249rschu1ze merged 7 commits intoClickHouse:masterfrom
--query parameters in clickhouse-client/local.#54249Conversation
|
This is an automated comment for commit fc105aa with description of existing statuses. It's updated for the latest CI running
|
|
Note to myself: Once merged, open an issue about #50357 (comment) |
| OK | ||
| 1 | ||
| FAIL | ||
| OK |
There was a problem hiding this comment.
Arguably looks weird. It corrects the garbage changes done to this and the corresponding "_with_prewhere.reference" file in #11923. This other PR made five test statements produce "Positional arguments are not supported" exceptions. But not the test statements were fixed, the expected results were adjusted... This meant that the test didn't test what it was supposed to test for three years. With my PR, clickhouse-client now behaves correctly, and I am reverting the expected results back to their actually expected values.
Fixes #49970
Continues #50357, kudos to @Ziy1-Tan
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes to CHANGELOG.md):
"clickhouse-local" and "clickhouse-client" now allow to specify the "--query" parameter multiple times, e.g. './clickhouse-client --query "SELECT 1" --query "SELECT 2"'. This syntax is slightly more intuitive than `./clickhouse-client --multiquery "SELECT 1;SELECT2", a bit easier to script (e.g. "queries.push_back('--query "$q"')") and more consistent with the behavior of existing parameter "--queries-file" (e.g. "./clickhouse client --queries-file queries1.sql --queries-file queries2.sql").