select Flfxdj, count(*) as num from lg_det_lril WHERE 1=1 ${if("SELECT distinct Category_Name FROM `DIM_DEPT` where Organization in ('"+Units_Involved+"')=='集团职能中心'","and Units_Involved in('各单位')","and Units_Involved in('各业务单元','各单位')")} group by Flfxdj 在if判断里面,我要根据参数Units_Involved去得到查询结果再判断,而不是直接根据参数判断,目前这样写,不管输入满足还是不满足的参数条件,最终输出的结果都是false,也就是根据后面的条件去查询;需要怎么调整或者还是不能这样写 |