diff --git a/programs/client/Client.cpp b/programs/client/Client.cpp index e51f2aff064..f3e7f1775b8 100644 --- a/programs/client/Client.cpp +++ b/programs/client/Client.cpp @@ -787,6 +787,7 @@ void Client::printHelpMessage(const OptionsDescription & options_description) { std::cout << options_description.main_description.value() << "\n"; std::cout << options_description.external_description.value() << "\n"; + std::cout << options_description.hosts_and_ports_description.value() << "\n"; std::cout << "In addition, --param_name=value can be specified for substitution of parameters for parametrized queries.\n"; } diff --git a/tests/queries/0_stateless/02239_client_host_help.reference b/tests/queries/0_stateless/02239_client_host_help.reference new file mode 100644 index 00000000000..2c94e483710 --- /dev/null +++ b/tests/queries/0_stateless/02239_client_host_help.reference @@ -0,0 +1,2 @@ +OK +OK diff --git a/tests/queries/0_stateless/02239_client_host_help.sh b/tests/queries/0_stateless/02239_client_host_help.sh new file mode 100755 index 00000000000..7b31b9d4dd7 --- /dev/null +++ b/tests/queries/0_stateless/02239_client_host_help.sh @@ -0,0 +1,9 @@ +#!/usr/bin/env bash + +CURDIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd) +# shellcheck source=../shell_config.sh +. "$CURDIR"/../shell_config.sh + +${CLICKHOUSE_CLIENT} --help | grep -q "\-\-host" && echo "OK" || echo "FAIL" +${CLICKHOUSE_CLIENT} --help | grep -q "\-\-port arg" && echo "OK" || echo "FAIL" +