高手看段代码,错误
select SRR_ID,SRR_Type,SRR_Source,SRR_Creator,SRR_CDate from SB_Repair_Record inner join
(case when SRR_Type='103' then SB_Repair_Declare on SFD_ID else SB_Repair_Plan on SRP_ID end) = SRR_Source
------解决方案--------------------
select SRR_ID,SRR_Type,SRR_Source,SRR_Creator,SRR_CDate
from SB_Repair_Record
inner join SB_Repair_Declare on SB_Repair_Declare.SFD_ID = SB_Repair_Record.SRR_Source
Where SB_Repair_Record.SRR_Type='103'
union all
select SRR_ID,SRR_Type,SRR_Source,SRR_Creator,SRR_CDate
from SB_Repair_Record
inner join SB_Repair_Plan on SB_Repair_Plan.SFD_ID = SB_Repair_Record.SRR_Source
Where SB_Repair_Record.SRR_Type <> '103'