SELECT order_date, sum(order_num) as order_num FROM `scm_order_inventory_statistics` WHERE 1=1 ${IF(LEN(日期)==0,""," where YEAR(order_date)=YEAR(NOW())")} group by order_date 但是这样实现不了,请问应该怎样写条件? 问题已解决,在原来的参数返回值为空的地方加上你想要的条件,and开头 参数为空查询全部- FineReport帮助文档 - 全面的报表使用教程和学习资料 https://help.fanruan.com/finereport/doc-view-4455.html |