langjiu-project/BI/销售业绩/销售回款明细-废弃.sql

8 lines
491 B
MySQL
Raw Permalink Normal View History

2024-11-24 15:21:04 +08:00
-- ======================================
-- 2024-11-21由李维调整完毕
-- ======================================
2024-09-20 17:28:15 +08:00
select * from dm.v_ag_sal_collection
where 1=1
${if(len(p_bill_code) == 0,"","and bill_code in ('" + p_bill_code + "')")}
${if(len(p_remark) == 0,"","and remark in ('" + p_remark + "')")}
${if(p_is_src_deal== "主经销商",if(len(p_deal_name)==0,"","and deal_name in ('" + p_deal_name + "')"),if(len(p_deal_name)==0,"","and src_deal_name in ('" + p_deal_name + "')"))}