* Add optional parentheses to TTL element and alter command
* Add some basic tests
* Extend tests with more test cases
* Add one more test case
* Add server setting to control new formatting behavior
* Automatic style fix
* Fix segfault in `clickhouse-format` related to new server setting
* Remove format_ttl_expressions_with_parentheses
* Fix unit test compilation failures
* Introduce global flag to control the new formatting behavior
* Revert "Fix segfault in `clickhouse-format` related to new server setting"
This reverts commit d7131a3145.
* Revert accidental changes
* Revert accidental include reorder
* Revert accidental changes
* Enable new format in client and local server
---------
Co-authored-by: robot-clickhouse <robot-clickhouse@users.noreply.github.com>
Components like client/server/... are very generic, and there is no
point in disabling them, since it does not reduce amount of compiled
code a lot anyway (just a few modules for entrypoints, everything else
is already included in the clickhouse binary), and eventually they are
just symlinks to the clickhouse binary.
But there are few, that requires extra libraries, like ODBC bridge or
keeper components (and there is also standalone keeper binary compiled
with musl), those had been kept.
Also add some descriptions for some utils and change exit code to 0 for
--help.
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
Before the following did not work, it always uses user `dev`, even with
`clickhouse-client --connection prod`:
```yaml
user: dev
connections_credentials:
prod:
name: prod
user: prod
```
The problem was that before it was not possible to distinguish options
that had been set via command line options and via configuration file.
I've splitted this two actions, and embedded a call to
parseConnectionsCredentials() in between.
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
This is required for client, to handle comments in multiquery mode.
v0: separate context for input format
v2: cannot use separate context since params and stuff are changed in global context
v3: do not sent this setting to the server (breaks queries for readonly profiles)
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
Added new type of authentication based on SSH keys. It works only for Native TCP protocol.
Co-authored-by: Nikita Mikhaylov <nikitamikhaylov@clickhouse.com>
Co-authored-by: Robert Schulze <robert@clickhouse.com>