AND CRE.AC_CRE_DT_MAX between replace('${授信开始}','-','') and replace('${授信结束}','-','')
${if(len(授信开始)>0 && len(授信结束)>0,"AND CRE.AC_CRE_DT_MAX between replace('"+授信开始+"','-','') and replace('"+授信结束+"','-','')","")}
这段的意思是当两个参数的长都都大于0的时候就带上这个条件 不然就返回空
动态条件,可参考:
http://help.finereport.com/doc-view-165.html