diff --git a/programs/client/Client.cpp b/programs/client/Client.cpp index 51040f06c48..383b9bb5e52 100644 --- a/programs/client/Client.cpp +++ b/programs/client/Client.cpp @@ -1003,7 +1003,6 @@ void Client::addOptions(OptionsDescription & options_description) ("password", po::value()->implicit_value("\n", ""), "password") ("ask-password", "ask-password") ("quota_key", po::value(), "A string to differentiate quotas when the user have keyed quotas configured on server") - ("pager", po::value(), "pager") ("testmode,T", "enable test hints in comments") ("max_client_network_bandwidth", po::value(), "the maximum speed of data exchange over the network for the client in bytes per second.") @@ -1104,8 +1103,6 @@ void Client::processOptions(const OptionsDescription & options_description, config().setString("host", options["host"].as()); if (options.count("interleave-queries-file")) interleave_queries_files = options["interleave-queries-file"].as>(); - if (options.count("pager")) - config().setString("pager", options["pager"].as()); if (options.count("port") && !options["port"].defaulted()) config().setInt("port", options["port"].as()); if (options.count("secure")) diff --git a/src/Client/ClientBase.cpp b/src/Client/ClientBase.cpp index 3998f558620..c56f614af83 100644 --- a/src/Client/ClientBase.cpp +++ b/src/Client/ClientBase.cpp @@ -1703,6 +1703,7 @@ void ClientBase::init(int argc, char ** argv) ("profile-events-delay-ms", po::value()->default_value(profile_events.delay_ms), "Delay between printing `ProfileEvents` packets (-1 - print only totals, 0 - print every single packet)") ("interactive", "Process queries-file or --query query and start interactive mode") + ("pager", po::value(), "Pipe all output into this command (less or similar)") ; addOptions(options_description); @@ -1774,6 +1775,8 @@ void ClientBase::init(int argc, char ** argv) config().setBool("verbose", true); if (options.count("interactive")) config().setBool("interactive", true); + if (options.count("pager")) + config().setString("pager", options["pager"].as()); if (options.count("log-level")) Poco::Logger::root().setLevel(options["log-level"].as());