報表下拉框多選查詢及一般在sql中添加查詢條件

1、sql

SELECT * FROM [銷量] 
where 
1=1 ${if(len(銷售員1) == 2,"","and 銷售員 in (" + 銷售員1 + ")")}

2、配置

注:https://bbs.fanruan.com/wenda/question1/69268.html

       https://bbs.fanruan.com/wenda/question/15290.html

       https://bbs.fanruan.com/wenda/question/19372.html

3、在sql中添加查詢條件

${if(len(qy)==0,""," and qy ='"+qy+"'")}

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章