ClickHouse/dbms/tests/queries/0_stateless/00118_storage_join.sql

12 lines
398 B
MySQL
Raw Normal View History

2019-06-07 16:02:24 +00:00
DROP TABLE IF EXISTS join;
2019-06-07 16:02:24 +00:00
CREATE TABLE join (k UInt64, s String) ENGINE = Join(ANY, LEFT, k);
2019-06-07 16:02:24 +00:00
INSERT INTO join VALUES (1, 'abc'), (2, 'def');
SELECT k, s FROM (SELECT number AS k FROM system.numbers LIMIT 10) js1 ANY LEFT JOIN join USING k;
2019-06-07 16:02:24 +00:00
INSERT INTO join VALUES (6, 'ghi');
SELECT k, s FROM (SELECT number AS k FROM system.numbers LIMIT 10) js1 ANY LEFT JOIN join USING k;
2019-06-07 16:02:24 +00:00
DROP TABLE join;