问题现象:成本管理模块中,材料及外购半成品耗用表取数的金额经常与材料出库单的金额不对,数量对。
解决方案:将有问题的存货重新期末处理,通过如下脚本可检查哪些存货、材料出库单与存货总帐上的差异率不一致: 注意具体用该脚本检查时,根据实际情况修改其中的a.imonth=9、b.cmonth=200509参数! --检查当月存货总帐差异率与材料出库单实际差异率是否一致: select c.iprice/c.iPPrice AS 单据上差异率,d.idifrate AS 存货总帐差异率,c.cinvcode as 存货编码,e.ccode as 材料出库单号,E.* from ia_subsidiary a inner join Inventory b on a.cinvcode=b.cinvcode inner join rdrecords c on a.id=c.autoid and a.cinvcode=c.cinvcode inner join rdrecord e on c.id=e.id inner join ia_summary d on a.imonth=d.imonth and a.cinvcode=d.cinvcode and ROUND(c.iprice/c.iPPrice,6)<>ROUND(1+d.idifrate,6) where a.imonth=9 and a.cvoutype='11' and a.bmoneyflag=0 and b.cmonth=200509