ClickHouse/tests/queries/0_stateless/02974_if_with_map.sql

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

21 lines
1.5 KiB
MySQL
Raw Normal View History

2024-01-31 09:24:51 +00:00
select if(number % 2 = 0, map(1,2,3,4), map(3,4,5,6)) from numbers(2);
select if(number % 2 = 0, materialize(map(1,2,3,4)), map(3,4,5,6)) from numbers(2);
select if(number % 2 = 0, map(3,4,5,6), materialize(map(1,2,3,4))) from numbers(2);
2024-02-01 03:13:26 +00:00
select if(number % 2 = 0, materialize(map(3,4,5,6)), materialize(map(1,2,3,4))) from numbers(2);
select if(number % 2 = 0, map(1,2,3,4), map(3,4)) from numbers(2);
select if(number % 2 = 0, materialize(map(1,2,3,4)), map(3,4)) from numbers(2);
select if(number % 2 = 0, map(3,4,5,6), materialize(map(1,2))) from numbers(2);
select if(number % 2 = 0, materialize(map(3,4,5,6)), materialize(map(1,2))) from numbers(2);
2024-01-31 09:24:51 +00:00
select if(1, map(1,2,3,4), map(3,4,5,6)) from numbers(2);
select if(0, map(1,2,3,4), map(3,4,5,6)) from numbers(2);
select if(null, map(1,2,3,4), map(3,4,5,6)) from numbers(2);
select if(1, materialize(map(1,2,3,4)), map(3,4,5,6)) from numbers(2);
select if(0, materialize(map(1,2,3,4)), map(3,4,5,6)) from numbers(2);
select if(null, materialize(map(1,2,3,4)), map(3,4,5,6)) from numbers(2);
select if(1, map(3,4,5,6), materialize(map(1,2,3,4))) from numbers(2);
select if(0, map(3,4,5,6), materialize(map(1,2,3,4))) from numbers(2);
select if(null, map(3,4,5,6), materialize(map(1,2,3,4))) from numbers(2);
select if(1, materialize(map(3,4,5,6)), materialize(map(1,2,3,4))) from numbers(2);
select if(0, materialize(map(3,4,5,6)), materialize(map(1,2,3,4))) from numbers(2);
select if(null, materialize(map(3,4,5,6)), materialize(map(1,2,3,4))) from numbers(2);