解决方案: |
请参照如下脚本检查实体帐套年初数据是否借贷方不等: 1、检查年初余额试算是否平衡(注意不是总帐启用时的期末余额): select code.cclass as cclass,code.cclass_engl as cclass_engl,sum(case when GL_accsum.cbegind_c=N'借' then GL_accsum.mb else -GL_accsum.mb end) as SumYe from code INNER JOIN GL_accsum ON GL_accsum.ccode=code.ccode WHERE GL_accsum.iperiod=1 and code.igrade=1 and code.cclass<>N'表外科目' GROUP BY code.cclass ,code.cclass_engl 2、检查期初余额中的借方累计、贷方累计是否相等: select sum(md) as smd,sum(mc) as smc from gl_accsum a inner join code b on a.ccode=b.ccode where b.bend=1 and iperiod=1 根据以上检查结果,调整为正确的数据即可。 修改前请务必做好数据备份! |