mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-15 02:41:59 +00:00
Add tests
This commit is contained in:
parent
b073d7a599
commit
5d35b19e7e
@ -0,0 +1 @@
|
|||||||
|
52
|
@ -0,0 +1,25 @@
|
|||||||
|
DROP TABLE IF EXISTS 02501_test;
|
||||||
|
DROP TABLE IF EXISTS 02501_dist;
|
||||||
|
DROP VIEW IF EXISTS 02501_view;
|
||||||
|
|
||||||
|
|
||||||
|
-- create local table
|
||||||
|
CREATE TABLE 02501_test(`a` UInt64) ENGINE = Memory;
|
||||||
|
|
||||||
|
-- create dist table
|
||||||
|
CREATE TABLE 02501_dist(`a` UInt64) ENGINE = Distributed(test_cluster_two_shards, currentDatabase(), 02501_test);
|
||||||
|
|
||||||
|
-- create view
|
||||||
|
CREATE VIEW 02501_view(`a` UInt64) AS SELECT a FROM 02501_dist;
|
||||||
|
|
||||||
|
-- insert data
|
||||||
|
insert into 02501_test values(5),(6),(7),(8);
|
||||||
|
|
||||||
|
-- test
|
||||||
|
SELECT * from 02501_view settings max_result_rows = 1; -- { serverError 396 }
|
||||||
|
SELECT sum(a) from 02501_view settings max_result_rows = 1;
|
||||||
|
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS 02501_test;
|
||||||
|
DROP TABLE IF EXISTS 02501_dist;
|
||||||
|
DROP VIEW IF EXISTS 02501_view;
|
Loading…
Reference in New Issue
Block a user