add more test cases as discussed on tg

This commit is contained in:
Alexander Kuzmenkov 2020-04-16 19:51:29 +03:00
parent 08d9734fc0
commit c7be8c226c
3 changed files with 16 additions and 2 deletions

View File

@ -5,3 +5,10 @@
xyzabc 2 xyzabc 2
1 3 1 3
1 2 0 0 1 2 0 0
1 0 0 3
\N 1 2 \N 0
\N 1 0 \N 3
1
1
1 hello\0\0\0
1 hello\0\0\0

View File

@ -11,4 +11,13 @@ with 3 as "1" select 1, "1";
-- https://github.com/ClickHouse/ClickHouse/issues/9953 -- https://github.com/ClickHouse/ClickHouse/issues/9953
select 1, * from (select 2 x) a left join (select 1, 3 y) b on y = x; select 1, * from (select 2 x) a left join (select 1, 3 y) b on y = x;
select 1, * from (select 2 x, 1) a right join (select 3 y) b on y = x;
select null, isConstant(null), * from (select 2 x) a left join (select null, 3 y) b on y = x;
select null, isConstant(null), * from (select 2 x, null) a right join (select 3 y) b on y = x;
-- other cases with joins and constants
select cast(1, 'UInt8') from (select arrayJoin([1, 2]) as a) t1 left join (select 1 as b) t2 on b = ignore('UInt8');
select isConstant('UInt8'), toFixedString('hello', toUInt8(substring('UInt8', 5, 1))) from (select arrayJoin([1, 2]) as a) t1 left join (select 1 as b) t2 on b = ignore('UInt8');

View File

@ -1,2 +0,0 @@
select cast(1, 'UInt8') from (select arrayJoin([1, 2]) as a) t1 left join (select 1 as b) t2 on b = ignore('UInt8');
select isConstant('UInt8'), toFixedString('hello', toUInt8(substring('UInt8', 5, 1))) from (select arrayJoin([1, 2]) as a) t1 left join (select 1 as b) t2 on b = ignore('UInt8');