mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-24 08:32:02 +00:00
Repro test
This commit is contained in:
parent
6c0615d493
commit
d09f5d18f1
@ -0,0 +1,2 @@
|
||||
105
|
||||
105
|
51
tests/queries/0_stateless/02967_prewhere_no_columns.sql
Normal file
51
tests/queries/0_stateless/02967_prewhere_no_columns.sql
Normal file
@ -0,0 +1,51 @@
|
||||
CREATE TABLE t_02967
|
||||
(
|
||||
`key` Date,
|
||||
`value` UInt16
|
||||
)
|
||||
ENGINE = MergeTree
|
||||
ORDER BY key
|
||||
SETTINGS
|
||||
index_granularity_bytes = 0 --8192 --, min_index_granularity_bytes = 2
|
||||
, index_granularity = 100
|
||||
, min_rows_for_wide_part = 0, min_bytes_for_wide_part = 0
|
||||
--
|
||||
-- , min_bytes_for_wide_part = 2
|
||||
AS SELECT
|
||||
number,
|
||||
repeat(toString(number), 5)
|
||||
FROM numbers(105.);
|
||||
|
||||
|
||||
|
||||
-- Check with newly inserted data part. It's in-memory structured are filled at insert time.
|
||||
SELECT
|
||||
count(ignore(*))
|
||||
FROM t_02967
|
||||
PREWHERE CAST(ignore() + 1 as UInt8)
|
||||
GROUP BY
|
||||
ignore(65535, *),
|
||||
ignore(255, 256, *)
|
||||
SETTINGS
|
||||
--send_logs_level='test',
|
||||
max_threads=1;
|
||||
|
||||
|
||||
|
||||
-- Reload part form disk to check that in-meory structures where properly serilaized-deserialized
|
||||
DETACH TABLE t_02967;
|
||||
ATTACH TABLE t_02967;
|
||||
|
||||
|
||||
SELECT
|
||||
count(ignore(*))
|
||||
FROM t_02967
|
||||
PREWHERE CAST(ignore() + 1 as UInt8)
|
||||
GROUP BY
|
||||
ignore(65535, *),
|
||||
ignore(255, 256, *)
|
||||
SETTINGS
|
||||
--send_logs_level='test',
|
||||
max_threads=1;
|
||||
|
||||
DROP TABLE t_02967;
|
Loading…
Reference in New Issue
Block a user