連接表組我有QUERY_1:如何通過計數
select id,
count(case when no01 ='B' then 1 END) +
count(case when no02='B' then 1 END) +
count(case when no03='B' then 1 END) as Count_All
From tabel_a
where date ='20150201'
group by id
,也是我有query_2:
select id, COUNT (*) from tabel_b
where ids <> 'T' and idt ='C'
group by id
我如何加入query_1與query_2 via id
?
謝謝基督教Goolhardt – SimanisJKT48 2015-03-31 05:01:05