我有3张桌子
答案 0 :(得分:-1)
您可以参考我的查询选项1.
select T1.kode,
T1.Nominal_spp,
T2.Nominal_antarjemput,
(IFNULL(T1.Nominal_spp, 0)*2 + IFNULL(T2.Nominal_antarjemput, 0)) as Total
from tb_spp as T1
left join tb_antarjemput as T2 on T1.kode = T2.kode