|
请各位高手指教。为什么a.crdcode='P1' and b.cFree1='国内' 显示为'国内购买'
当 a.crdcode='P1' and b.cFree1='进口' 显示为 '直接进口',执行以下语句时为什么不能显示“直接进口”的呢?请指教, 执行以下语句时,结果显示为附件中,请指教!多谢!各位高手!
select distinct a.id,cvouchtype ,cbustype,c.cwhname,ddate,ccode,
case
when a.crdcode='I1' then '车间领用'
when a.crdcode='I2' then '直接出口'
when a.crdcode='I4' then '其他料件退货单'
when a.crdcode='I5' then '料件转仓出库'
when a.crdcode='I6' then '料件盘亏单'
when a.crdcode='I7' then '其他使用'
when a.crdcode='I8' then '车间领用'
when a.crdcode='I9' then '车间领用'
when a.crdcode='P1' and b.cFree1='国内' then '国内购买'
when a.crdcode='P1' and b.cFree1='进口' then '直接进口'
when a.crdcode='P2' then '车间入库'
when a.crdcode='P3' then '国内购买'
when a.crdcode='P4' then '料件盘盈单'
when a.crdcode='P5' then '料件转仓入库'
when a.crdcode='P6' then '其他来源'
when a.crdcode='P7' then '国内购买'
when a.crdcode='P8' then '国内购买'
end crdcode ,d.cvenname,pd='N',SX='N'
from RdRecord a,RdRecords b,warehouse c,vendor d
where a.id=b.id and crdcode is not null and a.cwhcode=c.cwhcode and a.cvencode=d.cvencode
|
本帖子中包含更多资源
您需要 登录 才可以下载或查看,没有帐号?注册
x
|