This commit is contained in:
Alexander Kuzmenkov 2020-07-09 13:46:16 +03:00
parent 5b3a106f7a
commit 3b428d6585
3 changed files with 16 additions and 16 deletions

View File

@ -1,4 +1,8 @@
<test> <test>
<settings>
<max_memory_usage>20G</max_memory_usage>
</settings>
<create_query>CREATE TABLE t (x UInt64, d32 Decimal32(3), d64 Decimal64(4), d128 Decimal128(5)) ENGINE = Memory</create_query> <create_query>CREATE TABLE t (x UInt64, d32 Decimal32(3), d64 Decimal64(4), d128 Decimal128(5)) ENGINE = Memory</create_query>
<fill_query>INSERT INTO t SELECT number AS x, x % 1000000 AS d32, x AS d64, x d128 FROM numbers_mt(1000000000)</fill_query> <fill_query>INSERT INTO t SELECT number AS x, x % 1000000 AS d32, x AS d64, x d128 FROM numbers_mt(1000000000)</fill_query>
<drop_query>DROP TABLE IF EXISTS t</drop_query> <drop_query>DROP TABLE IF EXISTS t</drop_query>

View File

@ -4,6 +4,6 @@
</preconditions> </preconditions>
<query>SELECT count() FROM hits_100m_single WHERE NOT ignore(least(URL, Referer))</query> <query>SELECT count() FROM hits_100m_single WHERE NOT ignore(least(URL, Referer))</query>
<query>SELECT count() FROM hits_100m_single WHERE NOT ignore(greatest(URL, Referer, Title))</query> <query>SELECT count() FROM hits_10m_single WHERE NOT ignore(greatest(URL, Referer, Title))</query>
<query>SELECT count() FROM hits_100m_single WHERE NOT ignore(greatest(ClientIP, RemoteIP))</query> <query>SELECT count() FROM hits_100m_single WHERE NOT ignore(greatest(ClientIP, RemoteIP))</query>
</test> </test>

View File

@ -2,31 +2,27 @@
<settings> <settings>
<optimize_aggregation_in_order>1</optimize_aggregation_in_order> <optimize_aggregation_in_order>1</optimize_aggregation_in_order>
<optimize_read_in_order>1</optimize_read_in_order> <optimize_read_in_order>1</optimize_read_in_order>
<max_partitions_per_insert_block>200</max_partitions_per_insert_block> <max_partitions_per_insert_block>2000</max_partitions_per_insert_block>
<max_threads>8</max_threads> <max_threads>8</max_threads>
</settings> </settings>
<substitutions> <substitutions>
<substitution> <substitution>
<name>table</name> <name>parts</name>
<values> <values>
<value>mt_20_parts</value> <value>200</value>
<value>mt_200_parts</value> <value>2000</value>
</values> </values>
</substitution> </substitution>
</substitutions> </substitutions>
<create_query>CREATE TABLE mt_20_parts(id UInt32, val1 UInt32, val2 UInt32) ENGINE = MergeTree ORDER BY val1 PARTITION BY id % 20</create_query> <create_query>CREATE TABLE mt_{parts}_parts(id UInt32, val1 UInt32, val2 UInt32) ENGINE = MergeTree ORDER BY val1 PARTITION BY id % {parts}</create_query>
<create_query>CREATE TABLE mt_200_parts(id UInt32, val1 UInt32, val2 UInt32) ENGINE = MergeTree ORDER BY val1 PARTITION BY id % 200</create_query> <fill_query>INSERT INTO mt_{parts}_parts SELECT number, rand() % 10000, rand() FROM numbers_mt(100000000)</fill_query>
<fill_query>OPTIMIZE TABLE mt_{parts}_parts FINAL</fill_query>
<fill_query>INSERT INTO mt_20_parts SELECT number, rand() % 10000, rand() FROM numbers_mt(1000000000)</fill_query> <query>SELECT val2 FROM mt_{parts}_parts ORDER BY val1 LIMIT 1000 FORMAT Null</query>
<fill_query>INSERT INTO mt_200_parts SELECT number, rand() % 10000, rand() FROM numbers_mt(1000000000)</fill_query> <query>SELECT val2 FROM mt_{parts}_parts ORDER BY val1 LIMIT 100000 FORMAT Null</query>
<fill_query>OPTIMIZE TABLE mt_20_parts FINAL</fill_query> <query>SELECT sum(val2) FROM mt_{parts}_parts GROUP BY val1 FORMAT Null</query>
<fill_query>OPTIMIZE TABLE mt_200_parts FINAL</fill_query>
<query>SELECT val2 FROM {table} ORDER BY val1 LIMIT 100 FORMAT Null</query> <drop_query>DROP TABLE IF EXISTS mt_{parts}_parts</drop_query>
<query>SELECT val2 FROM {table} ORDER BY val1 LIMIT 100000 FORMAT Null</query>
<query>SELECT sum(val2) FROM {table} GROUP BY val1 FORMAT Null</query>
<drop_query>DROP TABLE IF EXISTS {table}</drop_query>
</test> </test>