ClickHouse/tests/queries/0_stateless/03008_index_small.sql

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

20 lines
441 B
MySQL
Raw Normal View History

2024-03-10 11:48:15 +00:00
DROP TABLE IF EXISTS test;
CREATE TABLE test (a UInt8, b UInt8) ENGINE = MergeTree ORDER BY (a, b)
SETTINGS index_granularity = 1, primary_key_ratio_of_unique_prefix_values_to_skip_suffix_columns = 0.01;
SET optimize_move_to_prewhere = 0;
INSERT INTO test
SELECT number DIV 2, number
FROM numbers(3);
SELECT count() FROM test WHERE b >= 0;
DETACH TABLE test;
ATTACH TABLE test;
SELECT count() FROM test WHERE b >= 0;
2024-03-10 23:42:44 +00:00
DROP TABLE test;