【发布时间】:2021-06-23 11:44:24
【问题描述】:
【问题讨论】:
【问题讨论】:
使用条件聚合:
select date, eurtousd,
max(case when car = 'Audi' then priceeur end) as audi,
max(case when car = 'BMW' then priceeur end) as bmw,
max(case when car = 'MB' then priceeur end) as mb
from t
group by date, eurtousd;
【讨论】:
union all。