sql语句: with a as(select distinct i.sku 物料编码, s.descr 物料名称, i.id LPN, i.qty 数量, i.qty - i.qtyallocated - i.qtypicked 可用量, i.qtyallocated 分配量, i.qtypicked 拣货量, case when i.status = 'OK' then '正常' else '冻结' end 库存状态, case when i.status = 'OK' then '合格' when i.status = 'HOLD' and ih.status is not null then to_char(ihc.description) else to_char(ihcloc.description) end 冻结状态, from lotxlocxid i ) select * from a where 1=1 ${if(len(kczt)==0,"","and 库存状态=('"+kczt+"')")} ${if(len(jhl)==0,"","and 拣货量=('"+jhl+"')")} |
最佳回答 |
||||
0
|
|