Clickhouse: How to control value of `Showed first 10000` in ch-client

Created on 24 Feb 2019  Β·  3Comments  Β·  Source: ClickHouse/ClickHouse

Is there any setting that controls default number of max rows printed to console by clickhouse-client?
If there is, such info could be added to https://clickhouse.yandex/docs/en/interfaces/formats/ where user can land on attempt to search for "Showed first 10000".
To be precise I am asking for client-side setting, so changing that value must not impact query optimization processes.

question

Most helpful comment

set output_format_pretty_max_rows = 3;
select * from numbers(100);

SELECT *
FROM numbers(100)

β”Œβ”€number─┐
β”‚      0 β”‚
β”‚      1 β”‚
β”‚      2 β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”˜
  Showed first 3.

100 rows in set. Elapsed: 0.001 sec.

All 3 comments

set output_format_pretty_max_rows = 3;
select * from numbers(100);

SELECT *
FROM numbers(100)

β”Œβ”€number─┐
β”‚      0 β”‚
β”‚      1 β”‚
β”‚      2 β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”˜
  Showed first 3.

100 rows in set. Elapsed: 0.001 sec.
select * from numbers(100) format Null;

SELECT *
FROM numbers(100)
FORMAT Null
100 rows in set. Elapsed: 0.001 sec.

Thanks

Was this page helpful?
0 / 5 - 0 ratings