应收款汇总表数据不一样

zmy 2020-10-15 371

delete icsaleentry where FInterID=(select FInterID from icsale where fbillno='发票号码') alter table icsale disable trigger all delete icsale where fbillno='PSEFP136774' alter table icsale enable trigger all
--填写发票号码,数据库执行。解决 删除发票 提示,上游单据不存在。


select * from t_RP_Contact where FType=3 and FIsInit=0
and FInvoiceID not in (select FInterID  from ICSale )
--查询已经删除的发票,但是应收款汇总表中依然显示的记录。锁定FID。
select * from t_RP_Plan_Ar where FOrgID ='FID'
--删除发票的收款计划。FOrgID等于上条语句中锁定的FID
delete from  t_RP_Contact where FType=3 and FIsInit=0
and FInvoiceID not in (select FInterID  from ICSale )
--删除应收款汇总表中的错误记录。
delete from t_RP_Plan_Ar where FOrgID ='FID'
--删除发票收款计划。FOrgID等于上条语句中锁定的FID



最新回复 (0)
返回
发新帖