mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-10 01:25:21 +00:00
fix test case
This commit is contained in:
parent
8522589483
commit
eed01abf65
@ -16,9 +16,9 @@ def start_cluster():
|
||||
|
||||
|
||||
def test_explain_estimates(start_cluster):
|
||||
node1.query("CREATE TABLE test (i Int64) ENGINE = MergeTree() ORDER BY i")
|
||||
node1.query("INSERT INTO test SELECT number FROM numbers(1000)")
|
||||
node1.query("CREATE TABLE test (i Int64) ENGINE = MergeTree() ORDER BY i SETTINGS index_granularity = 16, write_final_mark = 0")
|
||||
node1.query("INSERT INTO test SELECT number FROM numbers(128)")
|
||||
node1.query("OPTIMIZE TABLE test")
|
||||
system_parts_result = node1.query("SELECT any(database), any(table), count() as parts, sum(rows) as rows, sum(marks) as marks, sum(bytes_on_disk) as bytes FROM system.parts WHERE database = 'default' AND table = 'test' and active = 1 GROUP BY (database, table)")
|
||||
system_parts_result = node1.query("SELECT any(database), any(table), count() as parts, sum(rows) as rows, sum(marks) as marks FROM system.parts WHERE database = 'default' AND table = 'test' and active = 1 GROUP BY (database, table)")
|
||||
explain_estimates_result = node1.query("EXPLAIN ESTIMATE SELECT * FROM test")
|
||||
assert(system_parts_result == explain_estimates_result)
|
||||
|
Loading…
Reference in New Issue
Block a user