2023-02-08 15:48:18 +00:00
|
|
|
drop table if exists test;
|
|
|
|
create table test (x UInt64) engine=Memory();
|
|
|
|
set insert_null_as_default=1;
|
|
|
|
insert into test select number % 2 ? NULL : 42 as x from numbers(2);
|
2023-02-15 10:50:04 +00:00
|
|
|
select * from test order by x;
|
2023-02-08 15:48:18 +00:00
|
|
|
drop table test;
|
|
|
|
|
2023-02-08 19:24:04 +00:00
|
|
|
create table test (x LowCardinality(String) default 'Hello') engine=Memory();
|
|
|
|
insert into test select (number % 2 ? NULL : 'World')::LowCardinality(Nullable(String)) from numbers(2);
|
2023-02-15 10:50:04 +00:00
|
|
|
select * from test order by x;
|
2023-02-08 19:24:04 +00:00
|
|
|
drop table test;
|
|
|
|
|