mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-09-20 16:50:48 +00:00
Test to repro incorrect combined prewhere column
This commit is contained in:
parent
4adbcd4beb
commit
608b3703a1
@ -0,0 +1,26 @@
|
||||
DROP TABLE IF EXISTS t_02559;
|
||||
|
||||
CREATE TABLE t_02559 (
|
||||
key UInt64,
|
||||
value Array(String))
|
||||
ENGINE = MergeTree
|
||||
ORDER BY key
|
||||
SETTINGS index_granularity=400, min_bytes_for_wide_part=0;
|
||||
|
||||
INSERT INTO t_02559 SELECT number,
|
||||
if (number < 100 OR number > 1000,
|
||||
[toString(number)],
|
||||
emptyArrayString())
|
||||
FROM numbers(2000);
|
||||
|
||||
SET enable_multiple_prewhere_read_steps=1, move_all_conditions_to_prewhere=1;
|
||||
|
||||
SELECT * FROM t_02559
|
||||
WHERE (key < 5 OR key > 500)
|
||||
AND NOT has(value, toString(key))
|
||||
AND length(value) == 1
|
||||
LIMIT 10
|
||||
SETTINGS max_block_size = 81,
|
||||
max_threads = 1;
|
||||
|
||||
DROP TABLE IF EXISTS t_02559;
|
Loading…
Reference in New Issue
Block a user