速达5000出现计算成本数据溢出的问题

算成本提示某货品成本溢出处理方法,该问题是由于货品成本异常,成本上亿或者负亿造成的;

L8DB]XNOV0~[{]PEPLS~ORL

1.首先通过语句:select * into tmp_goods from l_goods where ABS(aprice)>=100000,把成本价格超过10万的货品资料取出;

2.更新货品资料的成本价格:

update g set aprice =0
from l_goods g where exists(select * from tmp_goods tg where tg.goodsid=g.goodsid);

3.更新底稿表的成本价格:

update g set price =0, amount=0, eprice=0, eamount=0, difamount=0
from aa_billflow g where exists(select * from tmp_goods tg where tg.goodsid=g.goodsid)

4.更新底稿表的重算状态

update aa_billflow set status=0;

5.然后重算成本,对负库存出库、有异常的成本做调价处理;

posted @ 2018-08-21 15:09  devsuperdata  阅读(1336)  评论(0编辑  收藏  举报
如果有不明白操作流程和使用方法,请及时与我们联系。