SELECT * FROM FH_Store WHERE shippedQty > 0 OR allocationQty > 0
${if(true,'AND ss.style = (SELECT style FROM FH_Goods WHERE cYear = '+cYear' and cSeason = '+cSeason+' and a.cInvCode = '+cInvCode+')'),''}
你这个sql不就是判断ss.style=后面的吗,直接sql写就行了啊。
select * from S订单
where 订单ID<10285 and 客户ID=
${"'"+SQL("FRDemo","select 客户ID from S订单 where 订单ID= '"+aa+"'",1,1)+"'"}
SELECT * FROM FH_Store WHERE (shippedQty > 0 OR allocationQty > 0)
AND ss.style = (SELECT style FROM FH_Goods WHERE cYear = '${cYear}' and cSeason = '${cSeason}' and a.cInvCode = '${cInvCode}')