时间:2021-07-01 10:21:17 帮助过:26人阅读
clickhouse 在关联不上的情况会返回0值,而不是MySQL返回Null
select * from
(select 1 as a union all
select 2 as a union all
select 3 as a union all
select 0 as a union all
select 0 as a) x
left join (
select 2 as b, ‘adc‘ as c union all
select 3 as b, ‘adc‘ as c union all
select 5 as b, ‘adc‘ as c union all
select 0 as b, ‘adc‘ as c union all
select 0 as b, ‘adc‘ as c
) y on x.a = y.b
-- where c= ‘‘
order by a
Clickhouse SQL查询技巧
标签:use 情况 order nio sql查询 null sql click 返回