ClickHouse/tests/queries/0_stateless/00609_mv_index_in_in.sql
Ivan 97f2a2213e
Move all folders inside /dbms one level up (#9974)
* Move some code outside dbms/src folder
* Fix paths
2020-04-02 02:51:21 +03:00

15 lines
548 B
SQL

DROP TABLE IF EXISTS test_00609;
DROP TABLE IF EXISTS test_mv_00609;
create table test_00609 (a Int8) engine=Memory;
insert into test_00609 values (1);
create materialized view test_mv_00609 Engine=MergeTree(date, (a), 8192) populate as select a, toDate('2000-01-01') date from test_00609;
select * from test_mv_00609; -- OK
select * from test_mv_00609 where a in (select a from test_mv_00609); -- EMPTY (bug)
select * from ".inner.test_mv_00609" where a in (select a from test_mv_00609); -- OK
DROP TABLE test_00609;
DROP TABLE test_mv_00609;